Run-Time Library (RTL) :
Reference guide.
Free Pascal version 3.0.2:
Reference guide for RTL units.
Document version 3.0.2
February 2017
Michaël Van Canneyt
Contents
0.1 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 127
1 Reference for unit ’BaseUnix’ 128
1.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 128
1.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 128
1.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 128
1.3.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 128
1.3.2 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 151
1.4 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 170
1.4.1 CreateShellArgV . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 170
1.4.2 FpAccess . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 171
1.4.3 FpAlarm . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 172
1.4.4 FpChdir . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 172
1.4.5 FpChmod . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 173
1.4.6 FpChown . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 174
1.4.7 FpClose . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 175
1.4.8 FpClosedir . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 175
1.4.9 FpDup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 176
1.4.10 FpDup2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 176
1.4.11 FpExecv . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 177
1.4.12 FpExecve . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 178
1.4.13 FpExit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 179
1.4.14 FpFcntl . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 180
1.4.15 fpfdfillset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 180
1.4.16 fpFD_CLR . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 181
1.4.17 fpFD_ISSET . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 181
1.4.18 fpFD_SET . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 181
1.4.19 fpFD_ZERO . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 181
1.4.20 FpFork . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 182
1.4.21 FPFStat . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 182
1.4.22 FpFtruncate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 183
1
CONTENTS
1.4.23 FpGetcwd . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 183
1.4.24 FpGetegid . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 184
1.4.25 FpGetEnv . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 184
1.4.26 fpgeterrno . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 185
1.4.27 FpGeteuid . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 185
1.4.28 FpGetgid . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 185
1.4.29 FpGetgroups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 186
1.4.30 FpGetpgrp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 186
1.4.31 FpGetpid . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 186
1.4.32 FpGetppid . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 187
1.4.33 fpGetPriority . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 187
1.4.34 FpGetRLimit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 188
1.4.35 FpGetsid . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 188
1.4.36 FpGetuid . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 188
1.4.37 FpIOCtl . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 189
1.4.38 FpKill . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 189
1.4.39 FpLink . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 190
1.4.40 FpLseek . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 191
1.4.41 fpLstat . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 191
1.4.42 FpMkdir . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 193
1.4.43 FpMkfifo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 193
1.4.44 Fpmmap . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 193
1.4.45 Fpmunmap . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 195
1.4.46 FpNanoSleep . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 195
1.4.47 fpNice . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 196
1.4.48 FpOpen . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 197
1.4.49 FpOpendir . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 198
1.4.50 FpPause . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 199
1.4.51 FpPipe . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 199
1.4.52 FpPoll . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 200
1.4.53 FppRead . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 200
1.4.54 FppWrite . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 201
1.4.55 FpRead . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 201
1.4.56 FpReaddir . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 202
1.4.57 fpReadLink . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 203
1.4.58 FpReadV . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 204
1.4.59 FpRename . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 204
1.4.60 FpRmdir . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 205
1.4.61 fpSelect . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 205
1.4.62 fpseterrno . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 207
2
CONTENTS
1.4.63 FpSetgid . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 207
1.4.64 fpSetPriority . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 207
1.4.65 FpSetRLimit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 208
1.4.66 FpSetsid . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 208
1.4.67 fpsettimeofday . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 208
1.4.68 FpSetuid . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 208
1.4.69 FPSigaction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 209
1.4.70 FpSigAddSet . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 210
1.4.71 FpSigDelSet . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 210
1.4.72 FpsigEmptySet . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 210
1.4.73 FpSigFillSet . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 211
1.4.74 FpSigIsMember . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 211
1.4.75 FpSignal . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 211
1.4.76 FpSigPending . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 212
1.4.77 FpSigProcMask . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 212
1.4.78 FpSigSuspend . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 213
1.4.79 FpSigTimedWait . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 213
1.4.80 FpSleep . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 213
1.4.81 FpStat . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 214
1.4.82 fpSymlink . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 215
1.4.83 fpS_ISBLK . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 216
1.4.84 fpS_ISCHR . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 216
1.4.85 fpS_ISDIR . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 217
1.4.86 fpS_ISFIFO . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 217
1.4.87 fpS_ISLNK . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 217
1.4.88 fpS_ISREG . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 218
1.4.89 fpS_ISSOCK . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 218
1.4.90 fptime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 218
1.4.91 FpTimes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 219
1.4.92 FpUmask . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 219
1.4.93 FpUname . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 220
1.4.94 FpUnlink . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 220
1.4.95 FpUtime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 220
1.4.96 FpWait . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 221
1.4.97 FpWaitPid . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 222
1.4.98 FpWrite . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 222
1.4.99 FpWriteV . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 223
1.4.100 FreeShellArgV . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 223
1.4.101 wexitStatus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 223
1.4.102 wifexited . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 223
3
CONTENTS
1.4.103 wifsignaled . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 224
1.4.104 wstopsig . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 224
1.4.105 wtermsig . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 224
2 Reference for unit ’character’ 225
2.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 225
2.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 225
2.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 225
2.3.1 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 225
2.4 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 227
2.4.1 ConvertFromUtf32 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 227
2.4.2 ConvertToUtf32 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 228
2.4.3 GetNumericValue . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 228
2.4.4 GetUnicodeCategory . . . . . . . . . . . . . . . . . . . . . . . . . . . . 228
2.4.5 IsControl . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 229
2.4.6 IsDigit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 229
2.4.7 IsHighSurrogate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 229
2.4.8 IsLetter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 229
2.4.9 IsLetterOrDigit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 230
2.4.10 IsLower . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 230
2.4.11 IsLowSurrogate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 230
2.4.12 IsNumber . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 230
2.4.13 IsPunctuation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 231
2.4.14 IsSeparator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 231
2.4.15 IsSurrogate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 231
2.4.16 IsSurrogatePair . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 231
2.4.17 IsSymbol . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 232
2.4.18 IsUpper . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 232
2.4.19 IsWhiteSpace . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 232
2.4.20 ToLower . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 232
2.4.21 ToUpper . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 233
2.5 TCharacter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 233
2.5.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 233
2.5.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 233
2.5.3 TCharacter.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 233
2.5.4 TCharacter.ConvertFromUtf32 . . . . . . . . . . . . . . . . . . . . . . . 234
2.5.5 TCharacter.ConvertToUtf32 . . . . . . . . . . . . . . . . . . . . . . . . . 234
2.5.6 TCharacter.GetNumericValue . . . . . . . . . . . . . . . . . . . . . . . . 235
2.5.7 TCharacter.GetUnicodeCategory . . . . . . . . . . . . . . . . . . . . . . 235
2.5.8 TCharacter.IsControl . . . . . . . . . . . . . . . . . . . . . . . . . . . . 235
4
CONTENTS
2.5.9 TCharacter.IsDigit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 236
2.5.10 TCharacter.IsSurrogate . . . . . . . . . . . . . . . . . . . . . . . . . . . 236
2.5.11 TCharacter.IsHighSurrogate . . . . . . . . . . . . . . . . . . . . . . . . . 237
2.5.12 TCharacter.IsLowSurrogate . . . . . . . . . . . . . . . . . . . . . . . . . 237
2.5.13 TCharacter.IsSurrogatePair . . . . . . . . . . . . . . . . . . . . . . . . . 237
2.5.14 TCharacter.IsLetter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 238
2.5.15 TCharacter.IsLetterOrDigit . . . . . . . . . . . . . . . . . . . . . . . . . 238
2.5.16 TCharacter.IsLower . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 239
2.5.17 TCharacter.IsNumber . . . . . . . . . . . . . . . . . . . . . . . . . . . . 239
2.5.18 TCharacter.IsPunctuation . . . . . . . . . . . . . . . . . . . . . . . . . . 240
2.5.19 TCharacter.IsSeparator . . . . . . . . . . . . . . . . . . . . . . . . . . . 240
2.5.20 TCharacter.IsSymbol . . . . . . . . . . . . . . . . . . . . . . . . . . . . 240
2.5.21 TCharacter.IsUpper . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 241
2.5.22 TCharacter.IsWhiteSpace . . . . . . . . . . . . . . . . . . . . . . . . . . 241
2.5.23 TCharacter.ToLower . . . . . . . . . . . . . . . . . . . . . . . . . . . . 242
2.5.24 TCharacter.ToUpper . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 242
3 Reference for unit ’charset’ 243
3.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 243
3.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 243
3.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 243
3.3.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 243
3.3.2 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 243
3.4 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 245
3.4.1 getascii . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 245
3.4.2 getmap . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 246
3.4.3 getunicode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 246
3.4.4 loadbinaryunicodemapping . . . . . . . . . . . . . . . . . . . . . . . . . 246
3.4.5 loadunicodemapping . . . . . . . . . . . . . . . . . . . . . . . . . . . . 247
3.4.6 mappingavailable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 247
3.4.7 registerbinarymapping . . . . . . . . . . . . . . . . . . . . . . . . . . . . 247
3.4.8 registermapping . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 248
4 Reference for unit ’Classes’ 249
4.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 249
4.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 249
4.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 249
4.3.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 249
4.3.2 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 252
4.3.3 Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 267
4.4 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 268
5
CONTENTS
4.4.1 ActivateClassGroup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 268
4.4.2 BeginGlobalLoading . . . . . . . . . . . . . . . . . . . . . . . . . . . . 268
4.4.3 BinToHex . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 269
4.4.4 Bounds . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 269
4.4.5 CheckSynchronize . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 269
4.4.6 ClassGroupOf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 270
4.4.7 CollectionsEqual . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 270
4.4.8 EndGlobalLoading . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 270
4.4.9 ExtractStrings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 270
4.4.10 FindClass . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 271
4.4.11 FindGlobalComponent . . . . . . . . . . . . . . . . . . . . . . . . . . . 271
4.4.12 FindIdentToInt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 271
4.4.13 FindIntToIdent . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 271
4.4.14 FindNestedComponent . . . . . . . . . . . . . . . . . . . . . . . . . . . 272
4.4.15 GetClass . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 272
4.4.16 GetFixupInstanceNames . . . . . . . . . . . . . . . . . . . . . . . . . . 272
4.4.17 GetFixupReferenceNames . . . . . . . . . . . . . . . . . . . . . . . . . 272
4.4.18 GlobalFixupReferences . . . . . . . . . . . . . . . . . . . . . . . . . . . 273
4.4.19 GroupDescendentsWith . . . . . . . . . . . . . . . . . . . . . . . . . . . 273
4.4.20 HexToBin . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 273
4.4.21 IdentToInt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 273
4.4.22 InitComponentRes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 274
4.4.23 InitInheritedComponent . . . . . . . . . . . . . . . . . . . . . . . . . . . 274
4.4.24 IntToIdent . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 274
4.4.25 InvalidPoint . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 274
4.4.26 LineStart . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 275
4.4.27 NotifyGlobalLoading . . . . . . . . . . . . . . . . . . . . . . . . . . . . 275
4.4.28 ObjectBinaryToText . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 275
4.4.29 ObjectResourceToText . . . . . . . . . . . . . . . . . . . . . . . . . . . 275
4.4.30 ObjectTextToBinary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 275
4.4.31 ObjectTextToResource . . . . . . . . . . . . . . . . . . . . . . . . . . . 276
4.4.32 Point . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 276
4.4.33 PointsEqual . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 276
4.4.34 ReadComponentRes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 276
4.4.35 ReadComponentResEx . . . . . . . . . . . . . . . . . . . . . . . . . . . 277
4.4.36 ReadComponentResFile . . . . . . . . . . . . . . . . . . . . . . . . . . . 277
4.4.37 Rect . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 277
4.4.38 RedirectFixupReferences . . . . . . . . . . . . . . . . . . . . . . . . . . 277
4.4.39 RegisterClass . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 278
4.4.40 RegisterClassAlias . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 278
6
CONTENTS
4.4.41 RegisterClasses . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 278
4.4.42 RegisterComponents . . . . . . . . . . . . . . . . . . . . . . . . . . . . 278
4.4.43 RegisterFindGlobalComponentProc . . . . . . . . . . . . . . . . . . . . 279
4.4.44 RegisterInitComponentHandler . . . . . . . . . . . . . . . . . . . . . . . 279
4.4.45 RegisterIntegerConsts . . . . . . . . . . . . . . . . . . . . . . . . . . . . 279
4.4.46 RegisterNoIcon . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 280
4.4.47 RegisterNonActiveX . . . . . . . . . . . . . . . . . . . . . . . . . . . . 280
4.4.48 RemoveFixupReferences . . . . . . . . . . . . . . . . . . . . . . . . . . 280
4.4.49 RemoveFixups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 281
4.4.50 SmallPoint . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 281
4.4.51 StartClassGroup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 281
4.4.52 UnRegisterClass . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 281
4.4.53 UnRegisterClasses . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 281
4.4.54 UnregisterFindGlobalComponentProc . . . . . . . . . . . . . . . . . . . 282
4.4.55 UnRegisterModuleClasses . . . . . . . . . . . . . . . . . . . . . . . . . 282
4.4.56 WriteComponentResFile . . . . . . . . . . . . . . . . . . . . . . . . . . 282
4.5 EBitsError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 282
4.5.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 282
4.6 EClassNotFound . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 283
4.6.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 283
4.7 EComponentError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 283
4.7.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 283
4.8 EFCreateError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 283
4.8.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 283
4.9 EFilerError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 283
4.9.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 283
4.10 EFOpenError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 283
4.10.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 283
4.11 EInvalidImage . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 284
4.11.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 284
4.12 EInvalidOperation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 284
4.12.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 284
4.13 EListError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 284
4.13.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 284
4.14 EMethodNotFound . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 284
4.14.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 284
4.15 EObserver . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 284
4.15.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 284
4.16 EOutOfResources . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 285
4.16.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 285
7
CONTENTS
4.17 EParserError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 285
4.17.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 285
4.18 EReadError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 285
4.18.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 285
4.19 EResNotFound . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 285
4.19.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 285
4.20 EStreamError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 285
4.20.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 285
4.21 EStringListError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 286
4.21.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 286
4.22 EThread . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 286
4.22.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 286
4.23 EThreadDestroyCalled . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 286
4.23.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 286
4.24 EThreadExternalException . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 286
4.24.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 286
4.25 EWriteError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 286
4.25.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 286
4.26 IDesignerNotify . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 287
4.26.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 287
4.26.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 287
4.26.3 IDesignerNotify.Modified . . . . . . . . . . . . . . . . . . . . . . . . . . 287
4.26.4 IDesignerNotify.Notification . . . . . . . . . . . . . . . . . . . . . . . . 287
4.27 IFPObserved . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 287
4.27.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 287
4.27.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 288
4.27.3 IFPObserved.FPOAttachObserver . . . . . . . . . . . . . . . . . . . . . 288
4.27.4 IFPObserved.FPODetachObserver . . . . . . . . . . . . . . . . . . . . . 288
4.27.5 IFPObserved.FPONotifyObservers . . . . . . . . . . . . . . . . . . . . . 288
4.28 IFPObserver . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 289
4.28.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 289
4.28.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 289
4.28.3 IFPObserver.FPOObservedChanged . . . . . . . . . . . . . . . . . . . . 289
4.29 IInterfaceComponentReference . . . . . . . . . . . . . . . . . . . . . . . . . . . . 289
4.29.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 289
4.29.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 290
4.29.3 IInterfaceComponentReference.GetComponent . . . . . . . . . . . . . . 290
4.30 IInterfaceList . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 290
4.30.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 290
4.30.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 290
8
CONTENTS
4.30.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 291
4.30.4 IInterfaceList.Get . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 291
4.30.5 IInterfaceList.GetCapacity . . . . . . . . . . . . . . . . . . . . . . . . . 291
4.30.6 IInterfaceList.GetCount . . . . . . . . . . . . . . . . . . . . . . . . . . . 291
4.30.7 IInterfaceList.Put . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 291
4.30.8 IInterfaceList.SetCapacity . . . . . . . . . . . . . . . . . . . . . . . . . . 292
4.30.9 IInterfaceList.SetCount . . . . . . . . . . . . . . . . . . . . . . . . . . . 292
4.30.10 IInterfaceList.Clear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 292
4.30.11 IInterfaceList.Delete . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 292
4.30.12 IInterfaceList.Exchange . . . . . . . . . . . . . . . . . . . . . . . . . . . 293
4.30.13 IInterfaceList.First . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 293
4.30.14 IInterfaceList.IndexOf . . . . . . . . . . . . . . . . . . . . . . . . . . . . 293
4.30.15 IInterfaceList.Add . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 293
4.30.16 IInterfaceList.Insert . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 293
4.30.17 IInterfaceList.Last . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 294
4.30.18 IInterfaceList.Remove . . . . . . . . . . . . . . . . . . . . . . . . . . . . 294
4.30.19 IInterfaceList.Lock . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 294
4.30.20 IInterfaceList.Unlock . . . . . . . . . . . . . . . . . . . . . . . . . . . . 294
4.30.21 IInterfaceList.Capacity . . . . . . . . . . . . . . . . . . . . . . . . . . . 294
4.30.22 IInterfaceList.Count . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 295
4.30.23 IInterfaceList.Items . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 295
4.31 IStreamPersist . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 295
4.31.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 295
4.31.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 295
4.31.3 IStreamPersist.LoadFromStream . . . . . . . . . . . . . . . . . . . . . . 296
4.31.4 IStreamPersist.SaveToStream . . . . . . . . . . . . . . . . . . . . . . . . 296
4.32 IStringsAdapter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 296
4.32.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 296
4.32.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 296
4.32.3 IStringsAdapter.ReferenceStrings . . . . . . . . . . . . . . . . . . . . . . 296
4.32.4 IStringsAdapter.ReleaseStrings . . . . . . . . . . . . . . . . . . . . . . . 296
4.33 IVCLComObject . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 297
4.33.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 297
4.33.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 297
4.33.3 IVCLComObject.GetTypeInfoCount . . . . . . . . . . . . . . . . . . . . 297
4.33.4 IVCLComObject.GetTypeInfo . . . . . . . . . . . . . . . . . . . . . . . 297
4.33.5 IVCLComObject.GetIDsOfNames . . . . . . . . . . . . . . . . . . . . . 298
4.33.6 IVCLComObject.Invoke . . . . . . . . . . . . . . . . . . . . . . . . . . 298
4.33.7 IVCLComObject.SafeCallException . . . . . . . . . . . . . . . . . . . . 298
4.33.8 IVCLComObject.FreeOnRelease . . . . . . . . . . . . . . . . . . . . . . 298
9
CONTENTS
4.34 TAbstractObjectReader . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 299
4.34.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 299
4.34.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 299
4.34.3 TAbstractObjectReader.NextValue . . . . . . . . . . . . . . . . . . . . . 299
4.34.4 TAbstractObjectReader.ReadValue . . . . . . . . . . . . . . . . . . . . . 300
4.34.5 TAbstractObjectReader.BeginRootComponent . . . . . . . . . . . . . . . 300
4.34.6 TAbstractObjectReader.BeginComponent . . . . . . . . . . . . . . . . . 300
4.34.7 TAbstractObjectReader.BeginProperty . . . . . . . . . . . . . . . . . . . 301
4.34.8 TAbstractObjectReader.Read . . . . . . . . . . . . . . . . . . . . . . . . 301
4.34.9 TAbstractObjectReader.ReadBinary . . . . . . . . . . . . . . . . . . . . 301
4.34.10 TAbstractObjectReader.ReadFloat . . . . . . . . . . . . . . . . . . . . . 301
4.34.11 TAbstractObjectReader.ReadSingle . . . . . . . . . . . . . . . . . . . . . 302
4.34.12 TAbstractObjectReader.ReadDate . . . . . . . . . . . . . . . . . . . . . . 302
4.34.13 TAbstractObjectReader.ReadCurrency . . . . . . . . . . . . . . . . . . . 302
4.34.14 TAbstractObjectReader.ReadIdent . . . . . . . . . . . . . . . . . . . . . 303
4.34.15 TAbstractObjectReader.ReadInt8 . . . . . . . . . . . . . . . . . . . . . . 303
4.34.16 TAbstractObjectReader.ReadInt16 . . . . . . . . . . . . . . . . . . . . . 303
4.34.17 TAbstractObjectReader.ReadInt32 . . . . . . . . . . . . . . . . . . . . . 304
4.34.18 TAbstractObjectReader.ReadInt64 . . . . . . . . . . . . . . . . . . . . . 304
4.34.19 TAbstractObjectReader.ReadSet . . . . . . . . . . . . . . . . . . . . . . 304
4.34.20 TAbstractObjectReader.ReadSignature . . . . . . . . . . . . . . . . . . . 305
4.34.21 TAbstractObjectReader.ReadStr . . . . . . . . . . . . . . . . . . . . . . 305
4.34.22 TAbstractObjectReader.ReadString . . . . . . . . . . . . . . . . . . . . . 305
4.34.23 TAbstractObjectReader.ReadWideString . . . . . . . . . . . . . . . . . . 306
4.34.24 TAbstractObjectReader.ReadUnicodeString . . . . . . . . . . . . . . . . 306
4.34.25 TAbstractObjectReader.SkipComponent . . . . . . . . . . . . . . . . . . 306
4.34.26 TAbstractObjectReader.SkipValue . . . . . . . . . . . . . . . . . . . . . 306
4.35 TAbstractObjectWriter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 307
4.35.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 307
4.35.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 307
4.35.3 TAbstractObjectWriter.BeginCollection . . . . . . . . . . . . . . . . . . 307
4.35.4 TAbstractObjectWriter.BeginComponent . . . . . . . . . . . . . . . . . . 307
4.35.5 TAbstractObjectWriter.WriteSignature . . . . . . . . . . . . . . . . . . . 308
4.35.6 TAbstractObjectWriter.BeginList . . . . . . . . . . . . . . . . . . . . . . 308
4.35.7 TAbstractObjectWriter.EndList . . . . . . . . . . . . . . . . . . . . . . . 308
4.35.8 TAbstractObjectWriter.BeginProperty . . . . . . . . . . . . . . . . . . . 308
4.35.9 TAbstractObjectWriter.EndProperty . . . . . . . . . . . . . . . . . . . . 308
4.35.10 TAbstractObjectWriter.Write . . . . . . . . . . . . . . . . . . . . . . . . 309
4.35.11 TAbstractObjectWriter.WriteBinary . . . . . . . . . . . . . . . . . . . . 309
4.35.12 TAbstractObjectWriter.WriteBoolean . . . . . . . . . . . . . . . . . . . . 309
10
CONTENTS
4.35.13 TAbstractObjectWriter.WriteFloat . . . . . . . . . . . . . . . . . . . . . 309
4.35.14 TAbstractObjectWriter.WriteSingle . . . . . . . . . . . . . . . . . . . . . 309
4.35.15 TAbstractObjectWriter.WriteDate . . . . . . . . . . . . . . . . . . . . . . 310
4.35.16 TAbstractObjectWriter.WriteCurrency . . . . . . . . . . . . . . . . . . . 310
4.35.17 TAbstractObjectWriter.WriteIdent . . . . . . . . . . . . . . . . . . . . . 310
4.35.18 TAbstractObjectWriter.WriteInteger . . . . . . . . . . . . . . . . . . . . 310
4.35.19 TAbstractObjectWriter.WriteUInt64 . . . . . . . . . . . . . . . . . . . . 310
4.35.20 TAbstractObjectWriter.WriteVariant . . . . . . . . . . . . . . . . . . . . 311
4.35.21 TAbstractObjectWriter.WriteMethodName . . . . . . . . . . . . . . . . . 311
4.35.22 TAbstractObjectWriter.WriteSet . . . . . . . . . . . . . . . . . . . . . . 311
4.35.23 TAbstractObjectWriter.WriteString . . . . . . . . . . . . . . . . . . . . . 311
4.35.24 TAbstractObjectWriter.WriteWideString . . . . . . . . . . . . . . . . . . 311
4.35.25 TAbstractObjectWriter.WriteUnicodeString . . . . . . . . . . . . . . . . 312
4.36 TBasicAction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 312
4.36.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 312
4.36.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 312
4.36.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 312
4.36.4 TBasicAction.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . 312
4.36.5 TBasicAction.Destroy . . . . . . . . . . . . . . . . . . . . . . . . . . . . 313
4.36.6 TBasicAction.HandlesTarget . . . . . . . . . . . . . . . . . . . . . . . . 313
4.36.7 TBasicAction.UpdateTarget . . . . . . . . . . . . . . . . . . . . . . . . . 313
4.36.8 TBasicAction.ExecuteTarget . . . . . . . . . . . . . . . . . . . . . . . . 314
4.36.9 TBasicAction.Execute . . . . . . . . . . . . . . . . . . . . . . . . . . . . 314
4.36.10 TBasicAction.RegisterChanges . . . . . . . . . . . . . . . . . . . . . . . 314
4.36.11 TBasicAction.UnRegisterChanges . . . . . . . . . . . . . . . . . . . . . 314
4.36.12 TBasicAction.Update . . . . . . . . . . . . . . . . . . . . . . . . . . . . 315
4.36.13 TBasicAction.ActionComponent . . . . . . . . . . . . . . . . . . . . . . 315
4.36.14 TBasicAction.OnExecute . . . . . . . . . . . . . . . . . . . . . . . . . . 315
4.36.15 TBasicAction.OnUpdate . . . . . . . . . . . . . . . . . . . . . . . . . . 316
4.37 TBasicActionLink . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 316
4.37.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 316
4.37.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 316
4.37.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 316
4.37.4 TBasicActionLink.Create . . . . . . . . . . . . . . . . . . . . . . . . . . 316
4.37.5 TBasicActionLink.Destroy . . . . . . . . . . . . . . . . . . . . . . . . . 317
4.37.6 TBasicActionLink.Execute . . . . . . . . . . . . . . . . . . . . . . . . . 317
4.37.7 TBasicActionLink.Update . . . . . . . . . . . . . . . . . . . . . . . . . 317
4.37.8 TBasicActionLink.Action . . . . . . . . . . . . . . . . . . . . . . . . . . 318
4.37.9 TBasicActionLink.OnChange . . . . . . . . . . . . . . . . . . . . . . . . 318
4.38 TBinaryObjectReader . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 318
11
CONTENTS
4.38.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 318
4.38.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 319
4.38.3 TBinaryObjectReader.Create . . . . . . . . . . . . . . . . . . . . . . . . 319
4.38.4 TBinaryObjectReader.Destroy . . . . . . . . . . . . . . . . . . . . . . . 319
4.38.5 TBinaryObjectReader.NextValue . . . . . . . . . . . . . . . . . . . . . . 320
4.38.6 TBinaryObjectReader.ReadValue . . . . . . . . . . . . . . . . . . . . . . 320
4.38.7 TBinaryObjectReader.BeginRootComponent . . . . . . . . . . . . . . . . 320
4.38.8 TBinaryObjectReader.BeginComponent . . . . . . . . . . . . . . . . . . 320
4.38.9 TBinaryObjectReader.BeginProperty . . . . . . . . . . . . . . . . . . . . 321
4.38.10 TBinaryObjectReader.Read . . . . . . . . . . . . . . . . . . . . . . . . . 321
4.38.11 TBinaryObjectReader.ReadBinary . . . . . . . . . . . . . . . . . . . . . 321
4.38.12 TBinaryObjectReader.ReadFloat . . . . . . . . . . . . . . . . . . . . . . 321
4.38.13 TBinaryObjectReader.ReadSingle . . . . . . . . . . . . . . . . . . . . . 321
4.38.14 TBinaryObjectReader.ReadDate . . . . . . . . . . . . . . . . . . . . . . 322
4.38.15 TBinaryObjectReader.ReadCurrency . . . . . . . . . . . . . . . . . . . . 322
4.38.16 TBinaryObjectReader.ReadIdent . . . . . . . . . . . . . . . . . . . . . . 322
4.38.17 TBinaryObjectReader.ReadInt8 . . . . . . . . . . . . . . . . . . . . . . . 322
4.38.18 TBinaryObjectReader.ReadInt16 . . . . . . . . . . . . . . . . . . . . . . 322
4.38.19 TBinaryObjectReader.ReadInt32 . . . . . . . . . . . . . . . . . . . . . . 323
4.38.20 TBinaryObjectReader.ReadInt64 . . . . . . . . . . . . . . . . . . . . . . 323
4.38.21 TBinaryObjectReader.ReadSet . . . . . . . . . . . . . . . . . . . . . . . 323
4.38.22 TBinaryObjectReader.ReadSignature . . . . . . . . . . . . . . . . . . . . 323
4.38.23 TBinaryObjectReader.ReadStr . . . . . . . . . . . . . . . . . . . . . . . 324
4.38.24 TBinaryObjectReader.ReadString . . . . . . . . . . . . . . . . . . . . . . 324
4.38.25 TBinaryObjectReader.ReadWideString . . . . . . . . . . . . . . . . . . . 324
4.38.26 TBinaryObjectReader.ReadUnicodeString . . . . . . . . . . . . . . . . . 324
4.38.27 TBinaryObjectReader.SkipComponent . . . . . . . . . . . . . . . . . . . 325
4.38.28 TBinaryObjectReader.SkipValue . . . . . . . . . . . . . . . . . . . . . . 325
4.39 TBinaryObjectWriter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 325
4.39.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 325
4.39.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 326
4.39.3 TBinaryObjectWriter.Create . . . . . . . . . . . . . . . . . . . . . . . . 326
4.39.4 TBinaryObjectWriter.Destroy . . . . . . . . . . . . . . . . . . . . . . . . 326
4.39.5 TBinaryObjectWriter.WriteSignature . . . . . . . . . . . . . . . . . . . . 326
4.39.6 TBinaryObjectWriter.BeginCollection . . . . . . . . . . . . . . . . . . . 327
4.39.7 TBinaryObjectWriter.BeginComponent . . . . . . . . . . . . . . . . . . 327
4.39.8 TBinaryObjectWriter.BeginList . . . . . . . . . . . . . . . . . . . . . . . 327
4.39.9 TBinaryObjectWriter.EndList . . . . . . . . . . . . . . . . . . . . . . . . 327
4.39.10 TBinaryObjectWriter.BeginProperty . . . . . . . . . . . . . . . . . . . . 327
4.39.11 TBinaryObjectWriter.EndProperty . . . . . . . . . . . . . . . . . . . . . 327
12
CONTENTS
4.39.12 TBinaryObjectWriter.Write . . . . . . . . . . . . . . . . . . . . . . . . . 328
4.39.13 TBinaryObjectWriter.WriteBinary . . . . . . . . . . . . . . . . . . . . . 328
4.39.14 TBinaryObjectWriter.WriteBoolean . . . . . . . . . . . . . . . . . . . . 328
4.39.15 TBinaryObjectWriter.WriteFloat . . . . . . . . . . . . . . . . . . . . . . 328
4.39.16 TBinaryObjectWriter.WriteSingle . . . . . . . . . . . . . . . . . . . . . 328
4.39.17 TBinaryObjectWriter.WriteDate . . . . . . . . . . . . . . . . . . . . . . 328
4.39.18 TBinaryObjectWriter.WriteCurrency . . . . . . . . . . . . . . . . . . . . 329
4.39.19 TBinaryObjectWriter.WriteIdent . . . . . . . . . . . . . . . . . . . . . . 329
4.39.20 TBinaryObjectWriter.WriteInteger . . . . . . . . . . . . . . . . . . . . . 329
4.39.21 TBinaryObjectWriter.WriteUInt64 . . . . . . . . . . . . . . . . . . . . . 329
4.39.22 TBinaryObjectWriter.WriteMethodName . . . . . . . . . . . . . . . . . 329
4.39.23 TBinaryObjectWriter.WriteSet . . . . . . . . . . . . . . . . . . . . . . . 329
4.39.24 TBinaryObjectWriter.WriteStr . . . . . . . . . . . . . . . . . . . . . . . 330
4.39.25 TBinaryObjectWriter.WriteString . . . . . . . . . . . . . . . . . . . . . . 330
4.39.26 TBinaryObjectWriter.WriteWideString . . . . . . . . . . . . . . . . . . . 330
4.39.27 TBinaryObjectWriter.WriteUnicodeString . . . . . . . . . . . . . . . . . 330
4.39.28 TBinaryObjectWriter.WriteVariant . . . . . . . . . . . . . . . . . . . . . 330
4.40 TBits . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 331
4.40.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 331
4.40.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 331
4.40.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 331
4.40.4 TBits.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 331
4.40.5 TBits.Destroy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 332
4.40.6 TBits.GetFSize . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 332
4.40.7 TBits.SetOn . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 332
4.40.8 TBits.Clear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 332
4.40.9 TBits.Clearall . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 333
4.40.10 TBits.AndBits . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 333
4.40.11 TBits.OrBits . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 333
4.40.12 TBits.XorBits . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 333
4.40.13 TBits.NotBits . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 334
4.40.14 TBits.Get . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 334
4.40.15 TBits.Grow . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 334
4.40.16 TBits.Equals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 335
4.40.17 TBits.SetIndex . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 335
4.40.18 TBits.FindFirstBit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 335
4.40.19 TBits.FindNextBit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 336
4.40.20 TBits.FindPrevBit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 336
4.40.21 TBits.OpenBit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 336
4.40.22 TBits.Bits . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 337
13
CONTENTS
4.40.23 TBits.Size . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 337
4.41 TBytesStream . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 337
4.41.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 337
4.41.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 337
4.41.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 337
4.41.4 TBytesStream.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . 338
4.41.5 TBytesStream.Bytes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 338
4.42 TCollection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 338
4.42.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 338
4.42.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 339
4.42.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 339
4.42.4 TCollection.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 339
4.42.5 TCollection.Destroy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 339
4.42.6 TCollection.Owner . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 340
4.42.7 TCollection.Add . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 340
4.42.8 TCollection.Assign . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 340
4.42.9 TCollection.BeginUpdate . . . . . . . . . . . . . . . . . . . . . . . . . . 340
4.42.10 TCollection.Clear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 341
4.42.11 TCollection.EndUpdate . . . . . . . . . . . . . . . . . . . . . . . . . . . 341
4.42.12 TCollection.Delete . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 341
4.42.13 TCollection.GetEnumerator . . . . . . . . . . . . . . . . . . . . . . . . . 342
4.42.14 TCollection.GetNamePath . . . . . . . . . . . . . . . . . . . . . . . . . 342
4.42.15 TCollection.Insert . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 342
4.42.16 TCollection.FindItemID . . . . . . . . . . . . . . . . . . . . . . . . . . . 342
4.42.17 TCollection.Exchange . . . . . . . . . . . . . . . . . . . . . . . . . . . . 343
4.42.18 TCollection.Sort . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 343
4.42.19 TCollection.Count . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 343
4.42.20 TCollection.ItemClass . . . . . . . . . . . . . . . . . . . . . . . . . . . . 344
4.42.21 TCollection.Items . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 344
4.43 TCollectionEnumerator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 344
4.43.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 344
4.43.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 344
4.43.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 345
4.43.4 TCollectionEnumerator.Create . . . . . . . . . . . . . . . . . . . . . . . 345
4.43.5 TCollectionEnumerator.GetCurrent . . . . . . . . . . . . . . . . . . . . . 345
4.43.6 TCollectionEnumerator.MoveNext . . . . . . . . . . . . . . . . . . . . . 345
4.43.7 TCollectionEnumerator.Current . . . . . . . . . . . . . . . . . . . . . . . 345
4.44 TCollectionItem . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 346
4.44.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 346
4.44.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 346
14
CONTENTS
4.44.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 346
4.44.4 TCollectionItem.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . 346
4.44.5 TCollectionItem.Destroy . . . . . . . . . . . . . . . . . . . . . . . . . . 346
4.44.6 TCollectionItem.GetNamePath . . . . . . . . . . . . . . . . . . . . . . . 347
4.44.7 TCollectionItem.Collection . . . . . . . . . . . . . . . . . . . . . . . . . 347
4.44.8 TCollectionItem.ID . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 347
4.44.9 TCollectionItem.Index . . . . . . . . . . . . . . . . . . . . . . . . . . . 348
4.44.10 TCollectionItem.DisplayName . . . . . . . . . . . . . . . . . . . . . . . 348
4.45 TComponent . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 348
4.45.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 348
4.45.2 Interfaces overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 349
4.45.3 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 349
4.45.4 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 349
4.45.5 TComponent.Notification . . . . . . . . . . . . . . . . . . . . . . . . . . 350
4.45.6 TComponent.WriteState . . . . . . . . . . . . . . . . . . . . . . . . . . 350
4.45.7 TComponent.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 350
4.45.8 TComponent.Destroy . . . . . . . . . . . . . . . . . . . . . . . . . . . . 351
4.45.9 TComponent.BeforeDestruction . . . . . . . . . . . . . . . . . . . . . . 351
4.45.10 TComponent.DestroyComponents . . . . . . . . . . . . . . . . . . . . . 351
4.45.11 TComponent.Destroying . . . . . . . . . . . . . . . . . . . . . . . . . . 351
4.45.12 TComponent.ExecuteAction . . . . . . . . . . . . . . . . . . . . . . . . 352
4.45.13 TComponent.FindComponent . . . . . . . . . . . . . . . . . . . . . . . . 352
4.45.14 TComponent.FreeNotification . . . . . . . . . . . . . . . . . . . . . . . 352
4.45.15 TComponent.RemoveFreeNotification . . . . . . . . . . . . . . . . . . . 352
4.45.16 TComponent.FreeOnRelease . . . . . . . . . . . . . . . . . . . . . . . . 353
4.45.17 TComponent.GetEnumerator . . . . . . . . . . . . . . . . . . . . . . . . 353
4.45.18 TComponent.GetNamePath . . . . . . . . . . . . . . . . . . . . . . . . . 353
4.45.19 TComponent.GetParentComponent . . . . . . . . . . . . . . . . . . . . . 353
4.45.20 TComponent.HasParent . . . . . . . . . . . . . . . . . . . . . . . . . . . 354
4.45.21 TComponent.InsertComponent . . . . . . . . . . . . . . . . . . . . . . . 354
4.45.22 TComponent.RemoveComponent . . . . . . . . . . . . . . . . . . . . . . 354
4.45.23 TComponent.SafeCallException . . . . . . . . . . . . . . . . . . . . . . 354
4.45.24 TComponent.SetSubComponent . . . . . . . . . . . . . . . . . . . . . . 355
4.45.25 TComponent.UpdateAction . . . . . . . . . . . . . . . . . . . . . . . . . 355
4.45.26 TComponent.IsImplementorOf . . . . . . . . . . . . . . . . . . . . . . . 355
4.45.27 TComponent.ReferenceInterface . . . . . . . . . . . . . . . . . . . . . . 355
4.45.28 TComponent.ComObject . . . . . . . . . . . . . . . . . . . . . . . . . . 356
4.45.29 TComponent.Components . . . . . . . . . . . . . . . . . . . . . . . . . 356
4.45.30 TComponent.ComponentCount . . . . . . . . . . . . . . . . . . . . . . . 356
4.45.31 TComponent.ComponentIndex . . . . . . . . . . . . . . . . . . . . . . . 356
15
CONTENTS
4.45.32 TComponent.ComponentState . . . . . . . . . . . . . . . . . . . . . . . 357
4.45.33 TComponent.ComponentStyle . . . . . . . . . . . . . . . . . . . . . . . 357
4.45.34 TComponent.DesignInfo . . . . . . . . . . . . . . . . . . . . . . . . . . 357
4.45.35 TComponent.Owner . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 358
4.45.36 TComponent.VCLComObject . . . . . . . . . . . . . . . . . . . . . . . 358
4.45.37 TComponent.Name . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 358
4.45.38 TComponent.Tag . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 358
4.46 TComponentEnumerator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 359
4.46.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 359
4.46.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 359
4.46.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 359
4.46.4 TComponentEnumerator.Create . . . . . . . . . . . . . . . . . . . . . . 359
4.46.5 TComponentEnumerator.GetCurrent . . . . . . . . . . . . . . . . . . . . 359
4.46.6 TComponentEnumerator.MoveNext . . . . . . . . . . . . . . . . . . . . 360
4.46.7 TComponentEnumerator.Current . . . . . . . . . . . . . . . . . . . . . . 360
4.47 TCustomMemoryStream . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 360
4.47.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 360
4.47.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 360
4.47.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 361
4.47.4 TCustomMemoryStream.Read . . . . . . . . . . . . . . . . . . . . . . . 361
4.47.5 TCustomMemoryStream.Seek . . . . . . . . . . . . . . . . . . . . . . . 361
4.47.6 TCustomMemoryStream.SaveToStream . . . . . . . . . . . . . . . . . . 361
4.47.7 TCustomMemoryStream.SaveToFile . . . . . . . . . . . . . . . . . . . . 362
4.47.8 TCustomMemoryStream.Memory . . . . . . . . . . . . . . . . . . . . . 362
4.48 TDataModule . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 362
4.48.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 362
4.48.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 363
4.48.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 363
4.48.4 TDataModule.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . 363
4.48.5 TDataModule.CreateNew . . . . . . . . . . . . . . . . . . . . . . . . . . 363
4.48.6 TDataModule.Destroy . . . . . . . . . . . . . . . . . . . . . . . . . . . . 363
4.48.7 TDataModule.AfterConstruction . . . . . . . . . . . . . . . . . . . . . . 364
4.48.8 TDataModule.BeforeDestruction . . . . . . . . . . . . . . . . . . . . . . 364
4.48.9 TDataModule.DesignOffset . . . . . . . . . . . . . . . . . . . . . . . . . 364
4.48.10 TDataModule.DesignSize . . . . . . . . . . . . . . . . . . . . . . . . . . 365
4.48.11 TDataModule.OnCreate . . . . . . . . . . . . . . . . . . . . . . . . . . . 365
4.48.12 TDataModule.OnDestroy . . . . . . . . . . . . . . . . . . . . . . . . . . 365
4.48.13 TDataModule.OldCreateOrder . . . . . . . . . . . . . . . . . . . . . . . 365
4.49 TFiler . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 366
4.49.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 366
16
CONTENTS
4.49.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 366
4.49.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 366
4.49.4 TFiler.DefineProperty . . . . . . . . . . . . . . . . . . . . . . . . . . . . 366
4.49.5 TFiler.DefineBinaryProperty . . . . . . . . . . . . . . . . . . . . . . . . 366
4.49.6 TFiler.Root . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 367
4.49.7 TFiler.LookupRoot . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 367
4.49.8 TFiler.Ancestor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 367
4.49.9 TFiler.IgnoreChildren . . . . . . . . . . . . . . . . . . . . . . . . . . . . 367
4.50 TFileStream . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 368
4.50.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 368
4.50.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 368
4.50.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 368
4.50.4 TFileStream.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 368
4.50.5 TFileStream.Destroy . . . . . . . . . . . . . . . . . . . . . . . . . . . . 369
4.50.6 TFileStream.FileName . . . . . . . . . . . . . . . . . . . . . . . . . . . 369
4.51 TFPList . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 369
4.51.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 369
4.51.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 370
4.51.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 370
4.51.4 TFPList.Destroy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 370
4.51.5 TFPList.AddList . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 371
4.51.6 TFPList.Add . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 371
4.51.7 TFPList.Clear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 371
4.51.8 TFPList.Delete . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 371
4.51.9 TFPList.Error . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 372
4.51.10 TFPList.Exchange . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 372
4.51.11 TFPList.Expand . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 372
4.51.12 TFPList.Extract . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 372
4.51.13 TFPList.First . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 373
4.51.14 TFPList.GetEnumerator . . . . . . . . . . . . . . . . . . . . . . . . . . . 373
4.51.15 TFPList.IndexOf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 373
4.51.16 TFPList.IndexOfItem . . . . . . . . . . . . . . . . . . . . . . . . . . . . 373
4.51.17 TFPList.Insert . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 374
4.51.18 TFPList.Last . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 374
4.51.19 TFPList.Move . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 374
4.51.20 TFPList.Assign . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 374
4.51.21 TFPList.Remove . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 375
4.51.22 TFPList.Pack . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 375
4.51.23 TFPList.Sort . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 375
4.51.24 TFPList.ForEachCall . . . . . . . . . . . . . . . . . . . . . . . . . . . . 375
17
CONTENTS
4.51.25 TFPList.Capacity . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 376
4.51.26 TFPList.Count . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 376
4.51.27 TFPList.Items . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 376
4.51.28 TFPList.List . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 377
4.52 TFPListEnumerator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 377
4.52.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 377
4.52.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 377
4.52.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 377
4.52.4 TFPListEnumerator.Create . . . . . . . . . . . . . . . . . . . . . . . . . 377
4.52.5 TFPListEnumerator.GetCurrent . . . . . . . . . . . . . . . . . . . . . . . 377
4.52.6 TFPListEnumerator.MoveNext . . . . . . . . . . . . . . . . . . . . . . . 378
4.52.7 TFPListEnumerator.Current . . . . . . . . . . . . . . . . . . . . . . . . . 378
4.53 THandleStream . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 378
4.53.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 378
4.53.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 379
4.53.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 379
4.53.4 THandleStream.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . 379
4.53.5 THandleStream.Read . . . . . . . . . . . . . . . . . . . . . . . . . . . . 379
4.53.6 THandleStream.Write . . . . . . . . . . . . . . . . . . . . . . . . . . . . 379
4.53.7 THandleStream.Seek . . . . . . . . . . . . . . . . . . . . . . . . . . . . 380
4.53.8 THandleStream.Handle . . . . . . . . . . . . . . . . . . . . . . . . . . . 380
4.54 TInterfacedPersistent . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 380
4.54.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 380
4.54.2 Interfaces overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 380
4.54.3 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 380
4.54.4 TInterfacedPersistent.QueryInterface . . . . . . . . . . . . . . . . . . . . 380
4.54.5 TInterfacedPersistent.AfterConstruction . . . . . . . . . . . . . . . . . . 381
4.55 TInterfaceList . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 381
4.55.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 381
4.55.2 Interfaces overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 381
4.55.3 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 381
4.55.4 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 382
4.55.5 TInterfaceList.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . 382
4.55.6 TInterfaceList.Destroy . . . . . . . . . . . . . . . . . . . . . . . . . . . 382
4.55.7 TInterfaceList.Clear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 382
4.55.8 TInterfaceList.Delete . . . . . . . . . . . . . . . . . . . . . . . . . . . . 382
4.55.9 TInterfaceList.Exchange . . . . . . . . . . . . . . . . . . . . . . . . . . 383
4.55.10 TInterfaceList.First . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 383
4.55.11 TInterfaceList.GetEnumerator . . . . . . . . . . . . . . . . . . . . . . . 383
4.55.12 TInterfaceList.IndexOf . . . . . . . . . . . . . . . . . . . . . . . . . . . 383
18
CONTENTS
4.55.13 TInterfaceList.Add . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 384
4.55.14 TInterfaceList.Insert . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 384
4.55.15 TInterfaceList.Last . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 384
4.55.16 TInterfaceList.Remove . . . . . . . . . . . . . . . . . . . . . . . . . . . 384
4.55.17 TInterfaceList.Lock . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 385
4.55.18 TInterfaceList.Unlock . . . . . . . . . . . . . . . . . . . . . . . . . . . . 385
4.55.19 TInterfaceList.Expand . . . . . . . . . . . . . . . . . . . . . . . . . . . . 385
4.55.20 TInterfaceList.Capacity . . . . . . . . . . . . . . . . . . . . . . . . . . . 385
4.55.21 TInterfaceList.Count . . . . . . . . . . . . . . . . . . . . . . . . . . . . 386
4.55.22 TInterfaceList.Items . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 386
4.56 TInterfaceListEnumerator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 386
4.56.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 386
4.56.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 386
4.56.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 386
4.56.4 TInterfaceListEnumerator.Create . . . . . . . . . . . . . . . . . . . . . . 387
4.56.5 TInterfaceListEnumerator.GetCurrent . . . . . . . . . . . . . . . . . . . 387
4.56.6 TInterfaceListEnumerator.MoveNext . . . . . . . . . . . . . . . . . . . . 387
4.56.7 TInterfaceListEnumerator.Current . . . . . . . . . . . . . . . . . . . . . 387
4.57 TList . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 388
4.57.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 388
4.57.2 Interfaces overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 388
4.57.3 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 388
4.57.4 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 389
4.57.5 TList.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 389
4.57.6 TList.Destroy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 389
4.57.7 TList.FPOAttachObserver . . . . . . . . . . . . . . . . . . . . . . . . . . 389
4.57.8 TList.FPODetachObserver . . . . . . . . . . . . . . . . . . . . . . . . . 389
4.57.9 TList.FPONotifyObservers . . . . . . . . . . . . . . . . . . . . . . . . . 390
4.57.10 TList.AddList . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 390
4.57.11 TList.Add . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 390
4.57.12 TList.Clear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 391
4.57.13 TList.Delete . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 391
4.57.14 TList.Error . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 391
4.57.15 TList.Exchange . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 391
4.57.16 TList.Expand . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 391
4.57.17 TList.Extract . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 392
4.57.18 TList.First . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 392
4.57.19 TList.GetEnumerator . . . . . . . . . . . . . . . . . . . . . . . . . . . . 392
4.57.20 TList.IndexOf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 393
4.57.21 TList.Insert . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 393
19
CONTENTS
4.57.22 TList.Last . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 393
4.57.23 TList.Move . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 393
4.57.24 TList.Assign . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 394
4.57.25 TList.Remove . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 394
4.57.26 TList.Pack . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 394
4.57.27 TList.Sort . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 394
4.57.28 TList.Capacity . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 395
4.57.29 TList.Count . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 395
4.57.30 TList.Items . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 395
4.57.31 TList.List . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 396
4.58 TListEnumerator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 396
4.58.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 396
4.58.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 396
4.58.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 396
4.58.4 TListEnumerator.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . 396
4.58.5 TListEnumerator.GetCurrent . . . . . . . . . . . . . . . . . . . . . . . . 396
4.58.6 TListEnumerator.MoveNext . . . . . . . . . . . . . . . . . . . . . . . . 397
4.58.7 TListEnumerator.Current . . . . . . . . . . . . . . . . . . . . . . . . . . 397
4.59 TMemoryStream . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 397
4.59.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 397
4.59.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 398
4.59.3 TMemoryStream.Destroy . . . . . . . . . . . . . . . . . . . . . . . . . . 398
4.59.4 TMemoryStream.Clear . . . . . . . . . . . . . . . . . . . . . . . . . . . 398
4.59.5 TMemoryStream.LoadFromStream . . . . . . . . . . . . . . . . . . . . . 398
4.59.6 TMemoryStream.LoadFromFile . . . . . . . . . . . . . . . . . . . . . . 399
4.59.7 TMemoryStream.SetSize . . . . . . . . . . . . . . . . . . . . . . . . . . 399
4.59.8 TMemoryStream.Write . . . . . . . . . . . . . . . . . . . . . . . . . . . 399
4.60 TOwnedCollection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 399
4.60.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 399
4.60.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 400
4.60.3 TOwnedCollection.Create . . . . . . . . . . . . . . . . . . . . . . . . . . 400
4.61 TOwnerStream . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 400
4.61.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 400
4.61.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 400
4.61.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 400
4.61.4 TOwnerStream.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . 400
4.61.5 TOwnerStream.Destroy . . . . . . . . . . . . . . . . . . . . . . . . . . . 401
4.61.6 TOwnerStream.Source . . . . . . . . . . . . . . . . . . . . . . . . . . . 401
4.61.7 TOwnerStream.SourceOwner . . . . . . . . . . . . . . . . . . . . . . . . 401
4.62 TParser . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 401
20
CONTENTS
4.62.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 401
4.62.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 402
4.62.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 402
4.62.4 TParser.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 402
4.62.5 TParser.Destroy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 402
4.62.6 TParser.CheckToken . . . . . . . . . . . . . . . . . . . . . . . . . . . . 403
4.62.7 TParser.CheckTokenSymbol . . . . . . . . . . . . . . . . . . . . . . . . 403
4.62.8 TParser.Error . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 403
4.62.9 TParser.ErrorFmt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 403
4.62.10 TParser.ErrorStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 403
4.62.11 TParser.HexToBinary . . . . . . . . . . . . . . . . . . . . . . . . . . . . 404
4.62.12 TParser.NextToken . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 404
4.62.13 TParser.SourcePos . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 404
4.62.14 TParser.TokenComponentIdent . . . . . . . . . . . . . . . . . . . . . . . 405
4.62.15 TParser.TokenFloat . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 405
4.62.16 TParser.TokenInt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 405
4.62.17 TParser.TokenString . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 406
4.62.18 TParser.TokenWideString . . . . . . . . . . . . . . . . . . . . . . . . . . 406
4.62.19 TParser.TokenSymbolIs . . . . . . . . . . . . . . . . . . . . . . . . . . . 406
4.62.20 TParser.FloatType . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 407
4.62.21 TParser.SourceLine . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 407
4.62.22 TParser.Token . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 407
4.63 TPersistent . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 408
4.63.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 408
4.63.2 Interfaces overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 408
4.63.3 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 408
4.63.4 TPersistent.Destroy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 408
4.63.5 TPersistent.Assign . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 409
4.63.6 TPersistent.FPOAttachObserver . . . . . . . . . . . . . . . . . . . . . . 409
4.63.7 TPersistent.FPODetachObserver . . . . . . . . . . . . . . . . . . . . . . 410
4.63.8 TPersistent.FPONotifyObservers . . . . . . . . . . . . . . . . . . . . . . 410
4.63.9 TPersistent.GetNamePath . . . . . . . . . . . . . . . . . . . . . . . . . . 410
4.64 TProxyStream . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 410
4.64.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 410
4.64.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 411
4.64.3 TProxyStream.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . 411
4.64.4 TProxyStream.Read . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 411
4.64.5 TProxyStream.Write . . . . . . . . . . . . . . . . . . . . . . . . . . . . 411
4.64.6 TProxyStream.Seek . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 411
4.64.7 TProxyStream.Check . . . . . . . . . . . . . . . . . . . . . . . . . . . . 411
21
CONTENTS
4.65 TReader . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 412
4.65.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 412
4.65.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 413
4.65.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 414
4.65.4 TReader.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 414
4.65.5 TReader.Destroy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 414
4.65.6 TReader.BeginReferences . . . . . . . . . . . . . . . . . . . . . . . . . . 414
4.65.7 TReader.CheckValue . . . . . . . . . . . . . . . . . . . . . . . . . . . . 415
4.65.8 TReader.DefineProperty . . . . . . . . . . . . . . . . . . . . . . . . . . . 415
4.65.9 TReader.DefineBinaryProperty . . . . . . . . . . . . . . . . . . . . . . . 415
4.65.10 TReader.EndOfList . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 415
4.65.11 TReader.EndReferences . . . . . . . . . . . . . . . . . . . . . . . . . . . 415
4.65.12 TReader.FixupReferences . . . . . . . . . . . . . . . . . . . . . . . . . . 416
4.65.13 TReader.NextValue . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 416
4.65.14 TReader.Read . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 416
4.65.15 TReader.ReadBoolean . . . . . . . . . . . . . . . . . . . . . . . . . . . . 416
4.65.16 TReader.ReadChar . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 416
4.65.17 TReader.ReadWideChar . . . . . . . . . . . . . . . . . . . . . . . . . . . 417
4.65.18 TReader.ReadUnicodeChar . . . . . . . . . . . . . . . . . . . . . . . . . 417
4.65.19 TReader.ReadCollection . . . . . . . . . . . . . . . . . . . . . . . . . . 417
4.65.20 TReader.ReadComponent . . . . . . . . . . . . . . . . . . . . . . . . . . 417
4.65.21 TReader.ReadComponents . . . . . . . . . . . . . . . . . . . . . . . . . 417
4.65.22 TReader.ReadFloat . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 418
4.65.23 TReader.ReadSingle . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 418
4.65.24 TReader.ReadDate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 418
4.65.25 TReader.ReadCurrency . . . . . . . . . . . . . . . . . . . . . . . . . . . 418
4.65.26 TReader.ReadIdent . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 418
4.65.27 TReader.ReadInteger . . . . . . . . . . . . . . . . . . . . . . . . . . . . 419
4.65.28 TReader.ReadInt64 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 419
4.65.29 TReader.ReadSet . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 419
4.65.30 TReader.ReadListBegin . . . . . . . . . . . . . . . . . . . . . . . . . . . 419
4.65.31 TReader.ReadListEnd . . . . . . . . . . . . . . . . . . . . . . . . . . . . 419
4.65.32 TReader.ReadRootComponent . . . . . . . . . . . . . . . . . . . . . . . 420
4.65.33 TReader.ReadVariant . . . . . . . . . . . . . . . . . . . . . . . . . . . . 420
4.65.34 TReader.ReadSignature . . . . . . . . . . . . . . . . . . . . . . . . . . . 420
4.65.35 TReader.ReadString . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 420
4.65.36 TReader.ReadWideString . . . . . . . . . . . . . . . . . . . . . . . . . . 421
4.65.37 TReader.ReadUnicodeString . . . . . . . . . . . . . . . . . . . . . . . . 421
4.65.38 TReader.ReadValue . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 421
4.65.39 TReader.CopyValue . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 421
22
CONTENTS
4.65.40 TReader.Driver . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 421
4.65.41 TReader.Owner . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 422
4.65.42 TReader.Parent . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 422
4.65.43 TReader.OnError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 422
4.65.44 TReader.OnPropertyNotFound . . . . . . . . . . . . . . . . . . . . . . . 422
4.65.45 TReader.OnFindMethod . . . . . . . . . . . . . . . . . . . . . . . . . . 423
4.65.46 TReader.OnSetMethodProperty . . . . . . . . . . . . . . . . . . . . . . . 423
4.65.47 TReader.OnSetName . . . . . . . . . . . . . . . . . . . . . . . . . . . . 423
4.65.48 TReader.OnReferenceName . . . . . . . . . . . . . . . . . . . . . . . . 423
4.65.49 TReader.OnAncestorNotFound . . . . . . . . . . . . . . . . . . . . . . . 423
4.65.50 TReader.OnCreateComponent . . . . . . . . . . . . . . . . . . . . . . . 424
4.65.51 TReader.OnFindComponentClass . . . . . . . . . . . . . . . . . . . . . . 424
4.65.52 TReader.OnReadStringProperty . . . . . . . . . . . . . . . . . . . . . . 424
4.66 TRecall . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 424
4.66.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 424
4.66.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 425
4.66.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 425
4.66.4 TRecall.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 425
4.66.5 TRecall.Destroy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 425
4.66.6 TRecall.Store . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 425
4.66.7 TRecall.Forget . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 426
4.66.8 TRecall.Reference . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 426
4.67 TResourceStream . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 426
4.67.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 426
4.67.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 426
4.67.3 TResourceStream.Create . . . . . . . . . . . . . . . . . . . . . . . . . . 427
4.67.4 TResourceStream.CreateFromID . . . . . . . . . . . . . . . . . . . . . . 427
4.67.5 TResourceStream.Destroy . . . . . . . . . . . . . . . . . . . . . . . . . 427
4.68 TStream . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 427
4.68.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 427
4.68.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 428
4.68.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 428
4.68.4 TStream.Read . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 428
4.68.5 TStream.Write . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 429
4.68.6 TStream.Seek . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 429
4.68.7 TStream.ReadBuffer . . . . . . . . . . . . . . . . . . . . . . . . . . . . 430
4.68.8 TStream.WriteBuffer . . . . . . . . . . . . . . . . . . . . . . . . . . . . 430
4.68.9 TStream.CopyFrom . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 431
4.68.10 TStream.ReadComponent . . . . . . . . . . . . . . . . . . . . . . . . . . 431
4.68.11 TStream.ReadComponentRes . . . . . . . . . . . . . . . . . . . . . . . . 431
23
CONTENTS
4.68.12 TStream.WriteComponent . . . . . . . . . . . . . . . . . . . . . . . . . 432
4.68.13 TStream.WriteComponentRes . . . . . . . . . . . . . . . . . . . . . . . 432
4.68.14 TStream.WriteDescendent . . . . . . . . . . . . . . . . . . . . . . . . . 432
4.68.15 TStream.WriteDescendentRes . . . . . . . . . . . . . . . . . . . . . . . 432
4.68.16 TStream.WriteResourceHeader . . . . . . . . . . . . . . . . . . . . . . . 433
4.68.17 TStream.FixupResourceHeader . . . . . . . . . . . . . . . . . . . . . . . 433
4.68.18 TStream.ReadResHeader . . . . . . . . . . . . . . . . . . . . . . . . . . 433
4.68.19 TStream.ReadByte . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 433
4.68.20 TStream.ReadWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 434
4.68.21 TStream.ReadDWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . 434
4.68.22 TStream.ReadQWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . 434
4.68.23 TStream.ReadAnsiString . . . . . . . . . . . . . . . . . . . . . . . . . . 435
4.68.24 TStream.WriteByte . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 435
4.68.25 TStream.WriteWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 435
4.68.26 TStream.WriteDWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . 435
4.68.27 TStream.WriteQWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . 436
4.68.28 TStream.WriteAnsiString . . . . . . . . . . . . . . . . . . . . . . . . . . 436
4.68.29 TStream.Position . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 436
4.68.30 TStream.Size . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 437
4.69 TStreamAdapter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 437
4.69.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 437
4.69.2 Interfaces overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 437
4.69.3 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 437
4.69.4 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 438
4.69.5 TStreamAdapter.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . 438
4.69.6 TStreamAdapter.Destroy . . . . . . . . . . . . . . . . . . . . . . . . . . 438
4.69.7 TStreamAdapter.Read . . . . . . . . . . . . . . . . . . . . . . . . . . . . 438
4.69.8 TStreamAdapter.Write . . . . . . . . . . . . . . . . . . . . . . . . . . . 438
4.69.9 TStreamAdapter.Seek . . . . . . . . . . . . . . . . . . . . . . . . . . . . 439
4.69.10 TStreamAdapter.SetSize . . . . . . . . . . . . . . . . . . . . . . . . . . 439
4.69.11 TStreamAdapter.CopyTo . . . . . . . . . . . . . . . . . . . . . . . . . . 439
4.69.12 TStreamAdapter.Commit . . . . . . . . . . . . . . . . . . . . . . . . . . 440
4.69.13 TStreamAdapter.Revert . . . . . . . . . . . . . . . . . . . . . . . . . . . 440
4.69.14 TStreamAdapter.LockRegion . . . . . . . . . . . . . . . . . . . . . . . . 440
4.69.15 TStreamAdapter.UnlockRegion . . . . . . . . . . . . . . . . . . . . . . . 440
4.69.16 TStreamAdapter.Stat . . . . . . . . . . . . . . . . . . . . . . . . . . . . 441
4.69.17 TStreamAdapter.Clone . . . . . . . . . . . . . . . . . . . . . . . . . . . 441
4.69.18 TStreamAdapter.Stream . . . . . . . . . . . . . . . . . . . . . . . . . . . 441
4.69.19 TStreamAdapter.StreamOwnership . . . . . . . . . . . . . . . . . . . . . 441
4.70 TStringList . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 442
24
CONTENTS
4.70.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 442
4.70.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 442
4.70.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 442
4.70.4 TStringList.Destroy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 442
4.70.5 TStringList.Add . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 443
4.70.6 TStringList.Clear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 443
4.70.7 TStringList.Delete . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 443
4.70.8 TStringList.Exchange . . . . . . . . . . . . . . . . . . . . . . . . . . . . 443
4.70.9 TStringList.Find . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 444
4.70.10 TStringList.IndexOf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 444
4.70.11 TStringList.Insert . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 444
4.70.12 TStringList.Sort . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 444
4.70.13 TStringList.CustomSort . . . . . . . . . . . . . . . . . . . . . . . . . . . 445
4.70.14 TStringList.Duplicates . . . . . . . . . . . . . . . . . . . . . . . . . . . 445
4.70.15 TStringList.Sorted . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 445
4.70.16 TStringList.CaseSensitive . . . . . . . . . . . . . . . . . . . . . . . . . . 446
4.70.17 TStringList.OnChange . . . . . . . . . . . . . . . . . . . . . . . . . . . 446
4.70.18 TStringList.OnChanging . . . . . . . . . . . . . . . . . . . . . . . . . . 446
4.70.19 TStringList.OwnsObjects . . . . . . . . . . . . . . . . . . . . . . . . . . 447
4.70.20 TStringList.SortStyle . . . . . . . . . . . . . . . . . . . . . . . . . . . . 447
4.71 TStrings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 447
4.71.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 447
4.71.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 448
4.71.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 449
4.71.4 TStrings.Destroy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 449
4.71.5 TStrings.Add . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 449
4.71.6 TStrings.AddObject . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 449
4.71.7 TStrings.Append . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 450
4.71.8 TStrings.AddStrings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 450
4.71.9 TStrings.AddText . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 450
4.71.10 TStrings.Assign . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 451
4.71.11 TStrings.BeginUpdate . . . . . . . . . . . . . . . . . . . . . . . . . . . . 451
4.71.12 TStrings.Clear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 451
4.71.13 TStrings.Delete . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 452
4.71.14 TStrings.EndUpdate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 452
4.71.15 TStrings.Equals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 452
4.71.16 TStrings.Exchange . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 453
4.71.17 TStrings.GetEnumerator . . . . . . . . . . . . . . . . . . . . . . . . . . 453
4.71.18 TStrings.GetText . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 453
4.71.19 TStrings.IndexOf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 453
25
CONTENTS
4.71.20 TStrings.IndexOfName . . . . . . . . . . . . . . . . . . . . . . . . . . . 454
4.71.21 TStrings.IndexOfObject . . . . . . . . . . . . . . . . . . . . . . . . . . . 454
4.71.22 TStrings.Insert . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 454
4.71.23 TStrings.InsertObject . . . . . . . . . . . . . . . . . . . . . . . . . . . . 455
4.71.24 TStrings.LoadFromFile . . . . . . . . . . . . . . . . . . . . . . . . . . . 455
4.71.25 TStrings.LoadFromStream . . . . . . . . . . . . . . . . . . . . . . . . . 455
4.71.26 TStrings.Move . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 455
4.71.27 TStrings.SaveToFile . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 456
4.71.28 TStrings.SaveToStream . . . . . . . . . . . . . . . . . . . . . . . . . . . 456
4.71.29 TStrings.SetText . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 457
4.71.30 TStrings.GetNameValue . . . . . . . . . . . . . . . . . . . . . . . . . . 457
4.71.31 TStrings.ExtractName . . . . . . . . . . . . . . . . . . . . . . . . . . . . 457
4.71.32 TStrings.TextLineBreakStyle . . . . . . . . . . . . . . . . . . . . . . . . 457
4.71.33 TStrings.Delimiter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 458
4.71.34 TStrings.DelimitedText . . . . . . . . . . . . . . . . . . . . . . . . . . . 458
4.71.35 TStrings.LineBreak . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 458
4.71.36 TStrings.StrictDelimiter . . . . . . . . . . . . . . . . . . . . . . . . . . . 459
4.71.37 TStrings.QuoteChar . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 459
4.71.38 TStrings.NameValueSeparator . . . . . . . . . . . . . . . . . . . . . . . 459
4.71.39 TStrings.ValueFromIndex . . . . . . . . . . . . . . . . . . . . . . . . . . 460
4.71.40 TStrings.Capacity . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 460
4.71.41 TStrings.CommaText . . . . . . . . . . . . . . . . . . . . . . . . . . . . 460
4.71.42 TStrings.Count . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 461
4.71.43 TStrings.Names . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 461
4.71.44 TStrings.Objects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 462
4.71.45 TStrings.Values . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 462
4.71.46 TStrings.Strings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 462
4.71.47 TStrings.Text . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 463
4.71.48 TStrings.StringsAdapter . . . . . . . . . . . . . . . . . . . . . . . . . . . 463
4.71.49 TStrings.SkipLastLineBreak . . . . . . . . . . . . . . . . . . . . . . . . 463
4.72 TStringsEnumerator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 464
4.72.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 464
4.72.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 464
4.72.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 464
4.72.4 TStringsEnumerator.Create . . . . . . . . . . . . . . . . . . . . . . . . . 464
4.72.5 TStringsEnumerator.GetCurrent . . . . . . . . . . . . . . . . . . . . . . 464
4.72.6 TStringsEnumerator.MoveNext . . . . . . . . . . . . . . . . . . . . . . . 465
4.72.7 TStringsEnumerator.Current . . . . . . . . . . . . . . . . . . . . . . . . 465
4.73 TStringStream . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 465
4.73.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 465
26
CONTENTS
4.73.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 465
4.73.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 465
4.73.4 TStringStream.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . 466
4.73.5 TStringStream.Read . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 466
4.73.6 TStringStream.ReadString . . . . . . . . . . . . . . . . . . . . . . . . . 466
4.73.7 TStringStream.Seek . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 466
4.73.8 TStringStream.Write . . . . . . . . . . . . . . . . . . . . . . . . . . . . 467
4.73.9 TStringStream.WriteString . . . . . . . . . . . . . . . . . . . . . . . . . 467
4.73.10 TStringStream.DataString . . . . . . . . . . . . . . . . . . . . . . . . . . 467
4.74 TTextObjectWriter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 467
4.74.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 467
4.75 TThread . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 467
4.75.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 467
4.75.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 468
4.75.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 468
4.75.4 TThread.Execute . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 468
4.75.5 TThread.Synchronize . . . . . . . . . . . . . . . . . . . . . . . . . . . . 469
4.75.6 TThread.Queue . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 469
4.75.7 TThread.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 469
4.75.8 TThread.Destroy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 469
4.75.9 TThread.CreateAnonymousThread . . . . . . . . . . . . . . . . . . . . . 470
4.75.10 TThread.NameThreadForDebugging . . . . . . . . . . . . . . . . . . . . 470
4.75.11 TThread.SetReturnValue . . . . . . . . . . . . . . . . . . . . . . . . . . 470
4.75.12 TThread.CheckTerminated . . . . . . . . . . . . . . . . . . . . . . . . . 470
4.75.13 TThread.RemoveQueuedEvents . . . . . . . . . . . . . . . . . . . . . . 471
4.75.14 TThread.SpinWait . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 471
4.75.15 TThread.Sleep . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 471
4.75.16 TThread.Yield . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 472
4.75.17 TThread.GetSystemTimes . . . . . . . . . . . . . . . . . . . . . . . . . . 472
4.75.18 TThread.GetTickCount . . . . . . . . . . . . . . . . . . . . . . . . . . . 472
4.75.19 TThread.GetTickCount64 . . . . . . . . . . . . . . . . . . . . . . . . . . 472
4.75.20 TThread.ExecuteInThread . . . . . . . . . . . . . . . . . . . . . . . . . 472
4.75.21 TThread.AfterConstruction . . . . . . . . . . . . . . . . . . . . . . . . . 477
4.75.22 TThread.Start . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 477
4.75.23 TThread.Resume . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 478
4.75.24 TThread.Suspend . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 478
4.75.25 TThread.Terminate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 478
4.75.26 TThread.WaitFor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 478
4.75.27 TThread.CurrentThread . . . . . . . . . . . . . . . . . . . . . . . . . . . 479
4.75.28 TThread.ProcessorCount . . . . . . . . . . . . . . . . . . . . . . . . . . 479
27
CONTENTS
4.75.29 TThread.IsSingleProcessor . . . . . . . . . . . . . . . . . . . . . . . . . 479
4.75.30 TThread.FreeOnTerminate . . . . . . . . . . . . . . . . . . . . . . . . . 480
4.75.31 TThread.Handle . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 480
4.75.32 TThread.ExternalThread . . . . . . . . . . . . . . . . . . . . . . . . . . 480
4.75.33 TThread.Priority . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 480
4.75.34 TThread.Suspended . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 480
4.75.35 TThread.Finished . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 481
4.75.36 TThread.ThreadID . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 481
4.75.37 TThread.OnTerminate . . . . . . . . . . . . . . . . . . . . . . . . . . . . 481
4.75.38 TThread.FatalException . . . . . . . . . . . . . . . . . . . . . . . . . . . 481
4.76 TThreadList . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 482
4.76.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 482
4.76.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 482
4.76.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 482
4.76.4 TThreadList.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 482
4.76.5 TThreadList.Destroy . . . . . . . . . . . . . . . . . . . . . . . . . . . . 482
4.76.6 TThreadList.Add . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 483
4.76.7 TThreadList.Clear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 483
4.76.8 TThreadList.LockList . . . . . . . . . . . . . . . . . . . . . . . . . . . . 483
4.76.9 TThreadList.Remove . . . . . . . . . . . . . . . . . . . . . . . . . . . . 483
4.76.10 TThreadList.UnlockList . . . . . . . . . . . . . . . . . . . . . . . . . . . 484
4.76.11 TThreadList.Duplicates . . . . . . . . . . . . . . . . . . . . . . . . . . . 484
4.77 TWriter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 484
4.77.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 484
4.77.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 485
4.77.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 485
4.77.4 TWriter.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 485
4.77.5 TWriter.Destroy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 486
4.77.6 TWriter.DefineProperty . . . . . . . . . . . . . . . . . . . . . . . . . . . 486
4.77.7 TWriter.DefineBinaryProperty . . . . . . . . . . . . . . . . . . . . . . . 486
4.77.8 TWriter.Write . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 486
4.77.9 TWriter.WriteBoolean . . . . . . . . . . . . . . . . . . . . . . . . . . . . 486
4.77.10 TWriter.WriteCollection . . . . . . . . . . . . . . . . . . . . . . . . . . 487
4.77.11 TWriter.WriteComponent . . . . . . . . . . . . . . . . . . . . . . . . . . 487
4.77.12 TWriter.WriteChar . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 487
4.77.13 TWriter.WriteWideChar . . . . . . . . . . . . . . . . . . . . . . . . . . . 487
4.77.14 TWriter.WriteDescendent . . . . . . . . . . . . . . . . . . . . . . . . . . 487
4.77.15 TWriter.WriteFloat . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 488
4.77.16 TWriter.WriteSingle . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 488
4.77.17 TWriter.WriteDate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 488
28
CONTENTS
4.77.18 TWriter.WriteCurrency . . . . . . . . . . . . . . . . . . . . . . . . . . . 488
4.77.19 TWriter.WriteIdent . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 488
4.77.20 TWriter.WriteInteger . . . . . . . . . . . . . . . . . . . . . . . . . . . . 489
4.77.21 TWriter.WriteSet . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 489
4.77.22 TWriter.WriteListBegin . . . . . . . . . . . . . . . . . . . . . . . . . . . 489
4.77.23 TWriter.WriteListEnd . . . . . . . . . . . . . . . . . . . . . . . . . . . . 489
4.77.24 TWriter.WriteSignature . . . . . . . . . . . . . . . . . . . . . . . . . . . 489
4.77.25 TWriter.WriteRootComponent . . . . . . . . . . . . . . . . . . . . . . . 490
4.77.26 TWriter.WriteString . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 490
4.77.27 TWriter.WriteWideString . . . . . . . . . . . . . . . . . . . . . . . . . . 490
4.77.28 TWriter.WriteUnicodeString . . . . . . . . . . . . . . . . . . . . . . . . 490
4.77.29 TWriter.WriteVariant . . . . . . . . . . . . . . . . . . . . . . . . . . . . 490
4.77.30 TWriter.RootAncestor . . . . . . . . . . . . . . . . . . . . . . . . . . . . 491
4.77.31 TWriter.OnFindAncestor . . . . . . . . . . . . . . . . . . . . . . . . . . 491
4.77.32 TWriter.OnWriteMethodProperty . . . . . . . . . . . . . . . . . . . . . . 491
4.77.33 TWriter.OnWriteStringProperty . . . . . . . . . . . . . . . . . . . . . . 491
4.77.34 TWriter.Driver . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 492
4.77.35 TWriter.PropertyPath . . . . . . . . . . . . . . . . . . . . . . . . . . . . 492
5 Reference for unit ’clocale’ 493
5.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 493
5.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 493
6 Reference for unit ’cmem’ 494
6.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 494
6.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 494
6.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 494
6.3.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 494
6.4 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 494
6.4.1 CAlloc . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 494
6.4.2 Free . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 495
6.4.3 Malloc . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 495
6.4.4 ReAlloc . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 495
7 Reference for unit ’collation_de’ 496
7.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 496
7.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 496
8 Reference for unit ’collation_es’ 497
8.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 497
8.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 497
29
CONTENTS
9 Reference for unit ’collation_fr_ca’ 498
9.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 498
9.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 498
10 Reference for unit ’collation_ja’ 499
10.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 499
10.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 499
11 Reference for unit ’collation_ko’ 500
11.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 500
11.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 500
12 Reference for unit ’collation_ru’ 501
12.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 501
12.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 501
13 Reference for unit ’collation_sv’ 502
13.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 502
13.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 502
14 Reference for unit ’collation_zh’ 503
14.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 503
14.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 503
15 Reference for unit ’cp1250’ 504
15.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 504
15.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 504
16 Reference for unit ’cp1251’ 505
16.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 505
16.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 505
17 Reference for unit ’cp1252’ 506
17.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 506
17.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 506
18 Reference for unit ’cp1253’ 507
18.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 507
18.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 507
19 Reference for unit ’cp1254’ 508
19.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 508
19.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 508
30
CONTENTS
20 Reference for unit ’cp1255’ 509
20.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 509
20.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 509
21 Reference for unit ’cp1256’ 510
21.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 510
21.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 510
22 Reference for unit ’cp1257’ 511
22.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 511
22.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 511
23 Reference for unit ’cp1258’ 512
23.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 512
23.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 512
24 Reference for unit ’cp437’ 513
24.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 513
24.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 513
25 Reference for unit ’cp646’ 514
25.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 514
25.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 514
26 Reference for unit ’cp850’ 515
26.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 515
26.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 515
27 Reference for unit ’cp852’ 516
27.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 516
27.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 516
28 Reference for unit ’cp856’ 517
28.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 517
28.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 517
29 Reference for unit ’cp866’ 518
29.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 518
29.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 518
30 Reference for unit ’cp874’ 519
30.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 519
30.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 519
31
CONTENTS
31 Reference for unit ’cp8859_1’ 520
31.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 520
31.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 520
32 Reference for unit ’cp8859_2’ 521
32.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 521
32.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 521
33 Reference for unit ’cp8859_5’ 522
33.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 522
33.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 522
34 Reference for unit ’cp895’ 523
34.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 523
34.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 523
35 Reference for unit ’cp932’ 524
35.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 524
35.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 524
36 Reference for unit ’cp936’ 525
36.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 525
36.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 525
37 Reference for unit ’cp949’ 526
37.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 526
37.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 526
38 Reference for unit ’cp950’ 527
38.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 527
38.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 527
39 Reference for unit ’cpall’ 528
39.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 528
39.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 528
40 Reference for unit ’Crt’ 529
40.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 529
40.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 529
40.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 530
40.3.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 530
40.3.2 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 532
40.3.3 Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 532
32
CONTENTS
40.4 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 533
40.4.1 AssignCrt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 533
40.4.2 ClrEol . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 534
40.4.3 ClrScr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 535
40.4.4 cursorbig . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 535
40.4.5 cursoroff . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 535
40.4.6 cursoron . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 536
40.4.7 Delay . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 536
40.4.8 DelLine . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 536
40.4.9 GotoXY . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 537
40.4.10 HighVideo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 538
40.4.11 InsLine . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 538
40.4.12 KeyPressed . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 539
40.4.13 LowVideo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 539
40.4.14 NormVideo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 540
40.4.15 NoSound . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 540
40.4.16 ReadKey . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 540
40.4.17 Sound . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 541
40.4.18 TextBackground . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 541
40.4.19 TextColor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 542
40.4.20 TextMode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 543
40.4.21 WhereX . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 543
40.4.22 WhereY . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 543
40.4.23 Window . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 544
41 Reference for unit ’cthreads’ 545
41.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 545
41.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 545
41.3 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 546
41.3.1 SetCThreadManager . . . . . . . . . . . . . . . . . . . . . . . . . . . . 546
42 Reference for unit ’ctypes’ 547
42.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 547
42.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 547
42.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 547
42.3.1 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 547
42.4 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 552
42.4.1 add(clongdouble,Double):Double . . . . . . . . . . . . . . . . . . . . . . 552
42.4.2 add(Double,clongdouble):Double . . . . . . . . . . . . . . . . . . . . . . 552
42.4.3 assign(clongdouble):Double . . . . . . . . . . . . . . . . . . . . . . . . 552
42.4.4 assign(Double):clongdouble . . . . . . . . . . . . . . . . . . . . . . . . 553
33
CONTENTS
42.4.5 divide(clongdouble,Double):Double . . . . . . . . . . . . . . . . . . . . 553
42.4.6 divide(Double,clongdouble):Double . . . . . . . . . . . . . . . . . . . . 553
42.4.7 equal(clongdouble,Double):Boolean . . . . . . . . . . . . . . . . . . . . 553
42.4.8 equal(Double,clongdouble):Boolean . . . . . . . . . . . . . . . . . . . . 553
42.4.9 greaterthan(clongdouble,Double):Boolean . . . . . . . . . . . . . . . . . 554
42.4.10 greaterthan(Double,clongdouble):Boolean . . . . . . . . . . . . . . . . . 554
42.4.11 greaterthanorequal(clongdouble,Double):Boolean . . . . . . . . . . . . . 554
42.4.12 greaterthanorequal(Double,clongdouble):Boolean . . . . . . . . . . . . . 554
42.4.13 lessthan(clongdouble,Double):Boolean . . . . . . . . . . . . . . . . . . . 554
42.4.14 lessthan(Double,clongdouble):Boolean . . . . . . . . . . . . . . . . . . . 555
42.4.15 lessthanorequal(clongdouble,Double):Boolean . . . . . . . . . . . . . . . 555
42.4.16 lessthanorequal(Double,clongdouble):Boolean . . . . . . . . . . . . . . . 555
42.4.17 multiply(clongdouble,Double):Double . . . . . . . . . . . . . . . . . . . 555
42.4.18 multiply(Double,clongdouble):Double . . . . . . . . . . . . . . . . . . . 555
42.4.19 subtract(clongdouble,Double):Double . . . . . . . . . . . . . . . . . . . 556
42.4.20 subtract(Double,clongdouble):Double . . . . . . . . . . . . . . . . . . . 556
43 Reference for unit ’cwstring’ 557
43.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 557
43.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 557
43.3 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 557
43.3.1 SetCWidestringManager . . . . . . . . . . . . . . . . . . . . . . . . . . 557
44 Reference for unit ’dateutils’ 559
44.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 559
44.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 559
44.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 559
44.3.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 559
44.4 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 561
44.4.1 CompareDate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 561
44.4.2 CompareDateTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 562
44.4.3 CompareTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 563
44.4.4 DateOf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 564
44.4.5 DateTimeToDosDateTime . . . . . . . . . . . . . . . . . . . . . . . . . 565
44.4.6 DateTimeToJulianDate . . . . . . . . . . . . . . . . . . . . . . . . . . . 565
44.4.7 DateTimeToMac . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 565
44.4.8 DateTimeToModifiedJulianDate . . . . . . . . . . . . . . . . . . . . . . 566
44.4.9 DateTimeToUnix . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 566
44.4.10 DayOf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 566
44.4.11 DayOfTheMonth . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 566
44.4.12 DayOfTheWeek . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 567
34
CONTENTS
44.4.13 DayOfTheYear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 567
44.4.14 DaysBetween . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 568
44.4.15 DaysInAMonth . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 568
44.4.16 DaysInAYear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 569
44.4.17 DaysInMonth . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 570
44.4.18 DaysInYear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 570
44.4.19 DaySpan . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 571
44.4.20 DecodeDateDay . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 571
44.4.21 DecodeDateMonthWeek . . . . . . . . . . . . . . . . . . . . . . . . . . 572
44.4.22 DecodeDateTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 573
44.4.23 DecodeDateWeek . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 573
44.4.24 DecodeDayOfWeekInMonth . . . . . . . . . . . . . . . . . . . . . . . . 574
44.4.25 DosDateTimeToDateTime . . . . . . . . . . . . . . . . . . . . . . . . . 574
44.4.26 EncodeDateDay . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 575
44.4.27 EncodeDateMonthWeek . . . . . . . . . . . . . . . . . . . . . . . . . . 575
44.4.28 EncodeDateTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 575
44.4.29 EncodeDateWeek . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 576
44.4.30 EncodeDayOfWeekInMonth . . . . . . . . . . . . . . . . . . . . . . . . 576
44.4.31 EncodeTimeInterval . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 576
44.4.32 EndOfADay . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 577
44.4.33 EndOfAMonth . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 577
44.4.34 EndOfAWeek . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 578
44.4.35 EndOfAYear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 579
44.4.36 EndOfTheDay . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 579
44.4.37 EndOfTheMonth . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 580
44.4.38 EndOfTheWeek . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 580
44.4.39 EndOfTheYear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 581
44.4.40 HourOf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 581
44.4.41 HourOfTheDay . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 582
44.4.42 HourOfTheMonth . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 582
44.4.43 HourOfTheWeek . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 582
44.4.44 HourOfTheYear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 583
44.4.45 HoursBetween . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 583
44.4.46 HourSpan . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 584
44.4.47 IncDay . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 585
44.4.48 IncHour . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 585
44.4.49 IncMilliSecond . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 586
44.4.50 IncMinute . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 586
44.4.51 IncSecond . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 587
44.4.52 IncWeek . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 587
35
CONTENTS
44.4.53 IncYear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 588
44.4.54 InvalidDateDayError . . . . . . . . . . . . . . . . . . . . . . . . . . . . 588
44.4.55 InvalidDateMonthWeekError . . . . . . . . . . . . . . . . . . . . . . . . 589
44.4.56 InvalidDateTimeError . . . . . . . . . . . . . . . . . . . . . . . . . . . . 589
44.4.57 InvalidDateWeekError . . . . . . . . . . . . . . . . . . . . . . . . . . . . 589
44.4.58 InvalidDayOfWeekInMonthError . . . . . . . . . . . . . . . . . . . . . . 590
44.4.59 IsInLeapYear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 590
44.4.60 IsPM . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 591
44.4.61 IsSameDay . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 591
44.4.62 IsSameMonth . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 592
44.4.63 IsToday . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 592
44.4.64 IsValidDate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 592
44.4.65 IsValidDateDay . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 593
44.4.66 IsValidDateMonthWeek . . . . . . . . . . . . . . . . . . . . . . . . . . . 593
44.4.67 IsValidDateTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 594
44.4.68 IsValidDateWeek . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 595
44.4.69 IsValidTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 596
44.4.70 JulianDateToDateTime . . . . . . . . . . . . . . . . . . . . . . . . . . . 596
44.4.71 LocalTimeToUniversal . . . . . . . . . . . . . . . . . . . . . . . . . . . 597
44.4.72 MacTimeStampToUnix . . . . . . . . . . . . . . . . . . . . . . . . . . . 597
44.4.73 MacToDateTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 597
44.4.74 MilliSecondOf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 597
44.4.75 MilliSecondOfTheDay . . . . . . . . . . . . . . . . . . . . . . . . . . . 598
44.4.76 MilliSecondOfTheHour . . . . . . . . . . . . . . . . . . . . . . . . . . . 598
44.4.77 MilliSecondOfTheMinute . . . . . . . . . . . . . . . . . . . . . . . . . . 598
44.4.78 MilliSecondOfTheMonth . . . . . . . . . . . . . . . . . . . . . . . . . . 599
44.4.79 MilliSecondOfTheSecond . . . . . . . . . . . . . . . . . . . . . . . . . . 599
44.4.80 MilliSecondOfTheWeek . . . . . . . . . . . . . . . . . . . . . . . . . . 599
44.4.81 MilliSecondOfTheYear . . . . . . . . . . . . . . . . . . . . . . . . . . . 600
44.4.82 MilliSecondsBetween . . . . . . . . . . . . . . . . . . . . . . . . . . . . 600
44.4.83 MilliSecondSpan . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 601
44.4.84 MinuteOf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 602
44.4.85 MinuteOfTheDay . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 602
44.4.86 MinuteOfTheHour . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 602
44.4.87 MinuteOfTheMonth . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 603
44.4.88 MinuteOfTheWeek . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 603
44.4.89 MinuteOfTheYear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 603
44.4.90 MinutesBetween . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 604
44.4.91 MinuteSpan . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 605
44.4.92 ModifiedJulianDateToDateTime . . . . . . . . . . . . . . . . . . . . . . 605
36
CONTENTS
44.4.93 MonthOf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 606
44.4.94 MonthOfTheYear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 606
44.4.95 MonthsBetween . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 606
44.4.96 MonthSpan . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 607
44.4.97 NthDayOfWeek . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 608
44.4.98 PeriodBetween . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 609
44.4.99 PreviousDayOfWeek . . . . . . . . . . . . . . . . . . . . . . . . . . . . 609
44.4.100 RecodeDate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 609
44.4.101 RecodeDateTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 610
44.4.102 RecodeDay . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 611
44.4.103 RecodeHour . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 611
44.4.104 RecodeMilliSecond . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 612
44.4.105 RecodeMinute . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 613
44.4.106 RecodeMonth . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 613
44.4.107 RecodeSecond . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 614
44.4.108 RecodeTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 615
44.4.109 RecodeYear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 615
44.4.110 SameDate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 616
44.4.111 SameDateTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 617
44.4.112 SameTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 618
44.4.113 ScanDateTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 618
44.4.114 SecondOf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 619
44.4.115 SecondOfTheDay . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 619
44.4.116 SecondOfTheHour . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 620
44.4.117 SecondOfTheMinute . . . . . . . . . . . . . . . . . . . . . . . . . . . . 620
44.4.118 SecondOfTheMonth . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 620
44.4.119 SecondOfTheWeek . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 621
44.4.120 SecondOfTheYear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 621
44.4.121 SecondsBetween . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 621
44.4.122 SecondSpan . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 622
44.4.123 StartOfADay . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 623
44.4.124 StartOfAMonth . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 624
44.4.125 StartOfAWeek . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 624
44.4.126 StartOfAYear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 625
44.4.127 StartOfTheDay . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 626
44.4.128 StartOfTheMonth . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 626
44.4.129 StartOfTheWeek . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 627
44.4.130 StartOfTheYear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 627
44.4.131 TimeOf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 628
44.4.132 Today . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 628
37
CONTENTS
44.4.133 Tomorrow . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 628
44.4.134 TryEncodeDateDay . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 629
44.4.135 TryEncodeDateMonthWeek . . . . . . . . . . . . . . . . . . . . . . . . . 629
44.4.136 TryEncodeDateTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . 630
44.4.137 TryEncodeDateWeek . . . . . . . . . . . . . . . . . . . . . . . . . . . . 631
44.4.138 TryEncodeDayOfWeekInMonth . . . . . . . . . . . . . . . . . . . . . . 632
44.4.139 TryEncodeTimeInterval . . . . . . . . . . . . . . . . . . . . . . . . . . . 632
44.4.140 TryJulianDateToDateTime . . . . . . . . . . . . . . . . . . . . . . . . . 633
44.4.141 TryModifiedJulianDateToDateTime . . . . . . . . . . . . . . . . . . . . 633
44.4.142 TryRecodeDateTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . 633
44.4.143 UniversalTimeToLocal . . . . . . . . . . . . . . . . . . . . . . . . . . . 634
44.4.144 UnixTimeStampToMac . . . . . . . . . . . . . . . . . . . . . . . . . . . 634
44.4.145 UnixToDateTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 635
44.4.146 WeekOf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 635
44.4.147 WeekOfTheMonth . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 635
44.4.148 WeekOfTheYear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 636
44.4.149 WeeksBetween . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 636
44.4.150 WeeksInAYear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 637
44.4.151 WeeksInYear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 638
44.4.152 WeekSpan . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 638
44.4.153 WithinPastDays . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 639
44.4.154 WithinPastHours . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 640
44.4.155 WithinPastMilliSeconds . . . . . . . . . . . . . . . . . . . . . . . . . . . 641
44.4.156 WithinPastMinutes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 642
44.4.157 WithinPastMonths . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 643
44.4.158 WithinPastSeconds . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 644
44.4.159 WithinPastWeeks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 645
44.4.160 WithinPastYears . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 646
44.4.161 YearOf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 647
44.4.162 YearsBetween . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 648
44.4.163 YearSpan . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 649
44.4.164 Yesterday . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 650
45 Reference for unit ’Dos’ 651
45.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 651
45.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 651
45.3 System information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 651
45.4 Process handling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 652
45.5 Directory and disk handling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 652
45.6 File handling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 653
38
CONTENTS
45.7 File open mode constants. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 653
45.8 File attributes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 653
45.9 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 654
45.9.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 654
45.9.2 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 655
45.9.3 Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 658
45.10 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 658
45.10.1 AddDisk . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 658
45.10.2 DiskFree . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 659
45.10.3 DiskSize . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 659
45.10.4 DosExitCode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 660
45.10.5 DosVersion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 660
45.10.6 DTToUnixDate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 661
45.10.7 EnvCount . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 661
45.10.8 EnvStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 662
45.10.9 Exec . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 662
45.10.10 FExpand . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 663
45.10.11 FindClose . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 663
45.10.12 FindFirst . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 663
45.10.13 FindNext . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 664
45.10.14 FSearch . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 664
45.10.15 FSplit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 665
45.10.16 GetCBreak . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 666
45.10.17 GetDate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 666
45.10.18 GetEnv . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 667
45.10.19 GetFAttr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 667
45.10.20 GetFTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 668
45.10.21 GetIntVec . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 669
45.10.22 GetLongName . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 669
45.10.23 GetMsCount . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 669
45.10.24 GetShortName . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 670
45.10.25 GetTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 670
45.10.26 GetVerify . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 671
45.10.27 Intr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 671
45.10.28 Keep . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 671
45.10.29 MSDos . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 672
45.10.30 PackTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 672
45.10.31 SetCBreak . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 673
45.10.32 SetDate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 673
45.10.33 SetFAttr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 673
39
CONTENTS
45.10.34 SetFTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 674
45.10.35 SetIntVec . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 674
45.10.36 SetTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 675
45.10.37 SetVerify . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 675
45.10.38 SwapVectors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 675
45.10.39 UnixDateToDt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 676
45.10.40 UnpackTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 676
45.10.41 weekday . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 676
46 Reference for unit ’dxeload’ 677
46.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 677
46.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 677
46.3 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 677
46.3.1 dxe_load . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 677
47 Reference for unit ’dynlibs’ 678
47.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 678
47.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 678
47.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 678
47.3.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 678
47.3.2 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 678
47.4 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 679
47.4.1 FreeLibrary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 679
47.4.2 GetLoadErrorStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 679
47.4.3 GetProcAddress . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 679
47.4.4 GetProcedureAddress . . . . . . . . . . . . . . . . . . . . . . . . . . . . 680
47.4.5 LoadLibrary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 680
47.4.6 SafeLoadLibrary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 680
47.4.7 UnloadLibrary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 681
48 Reference for unit ’emu387’ 682
48.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 682
48.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 682
48.3 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 682
48.3.1 npxsetup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 682
49 Reference for unit ’errors’ 684
49.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 684
49.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 684
49.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 684
49.3.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 684
40
CONTENTS
49.4 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 685
49.4.1 PError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 685
49.4.2 StrError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 686
50 Reference for unit ’exeinfo’ 687
50.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 687
50.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 687
50.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 687
50.3.1 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 687
50.4 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 688
50.4.1 CloseExeFile . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 688
50.4.2 FindExeSection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 688
50.4.3 GetModuleByAddr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 688
50.4.4 OpenExeFile . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 689
50.4.5 ReadDebugLink . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 689
51 Reference for unit ’fgl’ 690
51.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 690
51.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 690
51.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 690
51.3.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 690
51.3.2 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 690
51.4 EListError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 691
51.4.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 691
51.5 TFPGInterfacedObjectList . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 691
51.5.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 691
51.5.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 691
51.5.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 691
51.5.4 TFPGInterfacedObjectList.Create . . . . . . . . . . . . . . . . . . . . . 692
51.5.5 TFPGInterfacedObjectList.Add . . . . . . . . . . . . . . . . . . . . . . . 692
51.5.6 TFPGInterfacedObjectList.Extract . . . . . . . . . . . . . . . . . . . . . 692
51.5.7 TFPGInterfacedObjectList.GetEnumerator . . . . . . . . . . . . . . . . . 692
51.5.8 TFPGInterfacedObjectList.IndexOf . . . . . . . . . . . . . . . . . . . . . 693
51.5.9 TFPGInterfacedObjectList.Insert . . . . . . . . . . . . . . . . . . . . . . 693
51.5.10 TFPGInterfacedObjectList.Assign . . . . . . . . . . . . . . . . . . . . . 693
51.5.11 TFPGInterfacedObjectList.Remove . . . . . . . . . . . . . . . . . . . . . 693
51.5.12 TFPGInterfacedObjectList.Sort . . . . . . . . . . . . . . . . . . . . . . . 694
51.5.13 TFPGInterfacedObjectList.First . . . . . . . . . . . . . . . . . . . . . . . 694
51.5.14 TFPGInterfacedObjectList.Last . . . . . . . . . . . . . . . . . . . . . . . 694
51.5.15 TFPGInterfacedObjectList.Items . . . . . . . . . . . . . . . . . . . . . . 695
51.5.16 TFPGInterfacedObjectList.List . . . . . . . . . . . . . . . . . . . . . . . 695
41
CONTENTS
51.6 TFPGList . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 695
51.6.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 695
51.6.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 695
51.6.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 696
51.6.4 TFPGList.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 696
51.6.5 TFPGList.Add . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 696
51.6.6 TFPGList.Extract . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 696
51.6.7 TFPGList.GetEnumerator . . . . . . . . . . . . . . . . . . . . . . . . . . 696
51.6.8 TFPGList.IndexOf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 697
51.6.9 TFPGList.Insert . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 697
51.6.10 TFPGList.Assign . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 697
51.6.11 TFPGList.Remove . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 697
51.6.12 TFPGList.Sort . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 698
51.6.13 TFPGList.First . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 698
51.6.14 TFPGList.Last . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 698
51.6.15 TFPGList.Items . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 698
51.6.16 TFPGList.List . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 699
51.7 TFPGListEnumerator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 699
51.7.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 699
51.7.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 699
51.7.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 699
51.7.4 TFPGListEnumerator.Create . . . . . . . . . . . . . . . . . . . . . . . . 699
51.7.5 TFPGListEnumerator.MoveNext . . . . . . . . . . . . . . . . . . . . . . 700
51.7.6 TFPGListEnumerator.Current . . . . . . . . . . . . . . . . . . . . . . . . 700
51.8 TFPGMap . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 700
51.8.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 700
51.8.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 700
51.8.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 701
51.8.4 TFPGMap.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 701
51.8.5 TFPGMap.Add . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 701
51.8.6 TFPGMap.Find . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 701
51.8.7 TFPGMap.TryGetData . . . . . . . . . . . . . . . . . . . . . . . . . . . 702
51.8.8 TFPGMap.AddOrSetData . . . . . . . . . . . . . . . . . . . . . . . . . . 702
51.8.9 TFPGMap.IndexOf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 702
51.8.10 TFPGMap.IndexOfData . . . . . . . . . . . . . . . . . . . . . . . . . . . 702
51.8.11 TFPGMap.InsertKey . . . . . . . . . . . . . . . . . . . . . . . . . . . . 703
51.8.12 TFPGMap.InsertKeyData . . . . . . . . . . . . . . . . . . . . . . . . . . 703
51.8.13 TFPGMap.Remove . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 703
51.8.14 TFPGMap.Keys . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 703
51.8.15 TFPGMap.Data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 704
42
CONTENTS
51.8.16 TFPGMap.KeyData . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 704
51.8.17 TFPGMap.OnCompare . . . . . . . . . . . . . . . . . . . . . . . . . . . 704
51.8.18 TFPGMap.OnKeyCompare . . . . . . . . . . . . . . . . . . . . . . . . . 705
51.8.19 TFPGMap.OnDataCompare . . . . . . . . . . . . . . . . . . . . . . . . 705
51.9 TFPGMapInterfacedObjectData . . . . . . . . . . . . . . . . . . . . . . . . . . . . 705
51.9.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 705
51.9.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 706
51.9.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 706
51.9.4 TFPGMapInterfacedObjectData.Create . . . . . . . . . . . . . . . . . . . 706
51.9.5 TFPGMapInterfacedObjectData.Add . . . . . . . . . . . . . . . . . . . . 706
51.9.6 TFPGMapInterfacedObjectData.Find . . . . . . . . . . . . . . . . . . . . 707
51.9.7 TFPGMapInterfacedObjectData.TryGetData . . . . . . . . . . . . . . . . 707
51.9.8 TFPGMapInterfacedObjectData.AddOrSetData . . . . . . . . . . . . . . 707
51.9.9 TFPGMapInterfacedObjectData.IndexOf . . . . . . . . . . . . . . . . . . 707
51.9.10 TFPGMapInterfacedObjectData.IndexOfData . . . . . . . . . . . . . . . 708
51.9.11 TFPGMapInterfacedObjectData.InsertKey . . . . . . . . . . . . . . . . . 708
51.9.12 TFPGMapInterfacedObjectData.InsertKeyData . . . . . . . . . . . . . . 708
51.9.13 TFPGMapInterfacedObjectData.Remove . . . . . . . . . . . . . . . . . . 708
51.9.14 TFPGMapInterfacedObjectData.Keys . . . . . . . . . . . . . . . . . . . 709
51.9.15 TFPGMapInterfacedObjectData.Data . . . . . . . . . . . . . . . . . . . . 709
51.9.16 TFPGMapInterfacedObjectData.KeyData . . . . . . . . . . . . . . . . . 709
51.9.17 TFPGMapInterfacedObjectData.OnCompare . . . . . . . . . . . . . . . . 710
51.9.18 TFPGMapInterfacedObjectData.OnKeyCompare . . . . . . . . . . . . . 710
51.9.19 TFPGMapInterfacedObjectData.OnDataCompare . . . . . . . . . . . . . 710
51.10 TFPGMapObject . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 711
51.10.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 711
51.10.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 711
51.10.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 711
51.10.4 TFPGMapObject.Create . . . . . . . . . . . . . . . . . . . . . . . . . . 711
51.10.5 TFPGMapObject.Add . . . . . . . . . . . . . . . . . . . . . . . . . . . . 711
51.10.6 TFPGMapObject.Find . . . . . . . . . . . . . . . . . . . . . . . . . . . . 712
51.10.7 TFPGMapObject.TryGetData . . . . . . . . . . . . . . . . . . . . . . . . 712
51.10.8 TFPGMapObject.AddOrSetData . . . . . . . . . . . . . . . . . . . . . . 712
51.10.9 TFPGMapObject.IndexOf . . . . . . . . . . . . . . . . . . . . . . . . . . 713
51.10.10 TFPGMapObject.IndexOfData . . . . . . . . . . . . . . . . . . . . . . . 713
51.10.11 TFPGMapObject.InsertKey . . . . . . . . . . . . . . . . . . . . . . . . . 713
51.10.12 TFPGMapObject.InsertKeyData . . . . . . . . . . . . . . . . . . . . . . 713
51.10.13 TFPGMapObject.Remove . . . . . . . . . . . . . . . . . . . . . . . . . . 714
51.10.14 TFPGMapObject.Keys . . . . . . . . . . . . . . . . . . . . . . . . . . . 714
51.10.15 TFPGMapObject.Data . . . . . . . . . . . . . . . . . . . . . . . . . . . 714
43
CONTENTS
51.10.16 TFPGMapObject.KeyData . . . . . . . . . . . . . . . . . . . . . . . . . 715
51.10.17 TFPGMapObject.OnCompare . . . . . . . . . . . . . . . . . . . . . . . 715
51.10.18 TFPGMapObject.OnKeyCompare . . . . . . . . . . . . . . . . . . . . . 715
51.10.19 TFPGMapObject.OnDataCompare . . . . . . . . . . . . . . . . . . . . . 716
51.11 TFPGObjectList . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 716
51.11.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 716
51.11.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 716
51.11.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 716
51.11.4 TFPGObjectList.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . 717
51.11.5 TFPGObjectList.Add . . . . . . . . . . . . . . . . . . . . . . . . . . . . 717
51.11.6 TFPGObjectList.Extract . . . . . . . . . . . . . . . . . . . . . . . . . . 717
51.11.7 TFPGObjectList.GetEnumerator . . . . . . . . . . . . . . . . . . . . . . 717
51.11.8 TFPGObjectList.IndexOf . . . . . . . . . . . . . . . . . . . . . . . . . . 718
51.11.9 TFPGObjectList.Insert . . . . . . . . . . . . . . . . . . . . . . . . . . . 718
51.11.10 TFPGObjectList.Assign . . . . . . . . . . . . . . . . . . . . . . . . . . . 718
51.11.11 TFPGObjectList.Remove . . . . . . . . . . . . . . . . . . . . . . . . . . 718
51.11.12 TFPGObjectList.Sort . . . . . . . . . . . . . . . . . . . . . . . . . . . . 719
51.11.13 TFPGObjectList.First . . . . . . . . . . . . . . . . . . . . . . . . . . . . 719
51.11.14 TFPGObjectList.Last . . . . . . . . . . . . . . . . . . . . . . . . . . . . 719
51.11.15 TFPGObjectList.Items . . . . . . . . . . . . . . . . . . . . . . . . . . . 719
51.11.16 TFPGObjectList.List . . . . . . . . . . . . . . . . . . . . . . . . . . . . 720
51.11.17 TFPGObjectList.FreeObjects . . . . . . . . . . . . . . . . . . . . . . . . 720
51.12 TFPSList . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 720
51.12.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 720
51.12.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 721
51.12.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 721
51.12.4 TFPSList.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 721
51.12.5 TFPSList.Destroy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 721
51.12.6 TFPSList.Add . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 722
51.12.7 TFPSList.Clear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 722
51.12.8 TFPSList.Delete . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 722
51.12.9 TFPSList.Error . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 722
51.12.10 TFPSList.Exchange . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 723
51.12.11 TFPSList.Expand . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 723
51.12.12 TFPSList.Extract . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 723
51.12.13 TFPSList.IndexOf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 723
51.12.14 TFPSList.Insert . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 724
51.12.15 TFPSList.Move . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 724
51.12.16 TFPSList.Assign . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 724
51.12.17 TFPSList.Remove . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 725
44
CONTENTS
51.12.18 TFPSList.Pack . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 725
51.12.19 TFPSList.Sort . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 725
51.12.20 TFPSList.Capacity . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 726
51.12.21 TFPSList.Count . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 726
51.12.22 TFPSList.Items . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 726
51.12.23 TFPSList.ItemSize . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 727
51.12.24 TFPSList.List . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 727
51.12.25 TFPSList.First . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 727
51.12.26 TFPSList.Last . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 727
51.13 TFPSMap . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 728
51.13.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 728
51.13.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 728
51.13.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 728
51.13.4 TFPSMap.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 728
51.13.5 TFPSMap.Add . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 729
51.13.6 TFPSMap.Find . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 729
51.13.7 TFPSMap.IndexOf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 729
51.13.8 TFPSMap.IndexOfData . . . . . . . . . . . . . . . . . . . . . . . . . . . 730
51.13.9 TFPSMap.Insert . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 730
51.13.10 TFPSMap.InsertKey . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 730
51.13.11 TFPSMap.InsertKeyData . . . . . . . . . . . . . . . . . . . . . . . . . . 730
51.13.12 TFPSMap.Remove . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 731
51.13.13 TFPSMap.Sort . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 731
51.13.14 TFPSMap.Duplicates . . . . . . . . . . . . . . . . . . . . . . . . . . . . 731
51.13.15 TFPSMap.KeySize . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 732
51.13.16 TFPSMap.DataSize . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 732
51.13.17 TFPSMap.Keys . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 732
51.13.18 TFPSMap.Data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 732
51.13.19 TFPSMap.KeyData . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 733
51.13.20 TFPSMap.Sorted . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 733
51.13.21 TFPSMap.OnPtrCompare . . . . . . . . . . . . . . . . . . . . . . . . . . 733
51.13.22 TFPSMap.OnKeyPtrCompare . . . . . . . . . . . . . . . . . . . . . . . . 733
51.13.23 TFPSMap.OnDataPtrCompare . . . . . . . . . . . . . . . . . . . . . . . 734
52 Reference for unit ’fpwidestring’ 735
52.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 735
52.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 735
52.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 736
52.3.1 Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 736
52.4 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 736
45
CONTENTS
52.4.1 GetActiveCollation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 736
52.4.2 SetActiveCollation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 736
53 Reference for unit ’getopts’ 737
53.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 737
53.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 737
53.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 737
53.3.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 737
53.3.2 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 738
53.3.3 Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 738
53.4 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 739
53.4.1 GetLongOpts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 739
53.4.2 GetOpt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 739
54 Reference for unit ’go32’ 742
54.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 742
54.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 742
54.3 Real mode callbacks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 742
54.4 Executing software interrupts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 743
54.5 Software interrupts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 746
54.6 Hardware interrupts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 746
54.7 Disabling interrupts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 748
54.8 Creating your own interrupt handlers . . . . . . . . . . . . . . . . . . . . . . . . . 748
54.9 Protected mode interrupts vs. Real mode interrupts . . . . . . . . . . . . . . . . . . 749
54.10 Handling interrupts with DPMI . . . . . . . . . . . . . . . . . . . . . . . . . . . . 749
54.11 Interrupt redirection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 749
54.12 Processor access . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 749
54.13 I/O port access . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 749
54.14 dos memory access . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 749
54.15 FPC specialities . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 750
54.16 Selectors and descriptors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 750
54.17 What is DPMI . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 750
54.18 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 750
54.18.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 750
54.18.2 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 753
54.18.3 Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 756
54.19 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 757
54.19.1 allocate_ldt_descriptors . . . . . . . . . . . . . . . . . . . . . . . . . . . 757
54.19.2 allocate_memory_block . . . . . . . . . . . . . . . . . . . . . . . . . . . 760
54.19.3 copyfromdos . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 760
54.19.4 copytodos . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 761
46
CONTENTS
54.19.5 create_code_segment_alias_descriptor . . . . . . . . . . . . . . . . . . . 761
54.19.6 disable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 761
54.19.7 dpmi_dosmemfillchar . . . . . . . . . . . . . . . . . . . . . . . . . . . . 762
54.19.8 dpmi_dosmemfillword . . . . . . . . . . . . . . . . . . . . . . . . . . . 762
54.19.9 dpmi_dosmemget . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 762
54.19.10 dpmi_dosmemmove . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 762
54.19.11 dpmi_dosmemput . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 763
54.19.12 enable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 763
54.19.13 free_ldt_descriptor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 763
54.19.14 free_linear_addr_mapping . . . . . . . . . . . . . . . . . . . . . . . . . 763
54.19.15 free_memory_block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 764
54.19.16 free_rm_callback . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 764
54.19.17 get_cs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 764
54.19.18 get_descriptor_access_right . . . . . . . . . . . . . . . . . . . . . . . . . 765
54.19.19 get_dpmi_version . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 765
54.19.20 get_ds . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 765
54.19.21 get_exception_handler . . . . . . . . . . . . . . . . . . . . . . . . . . . 765
54.19.22 get_linear_addr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 766
54.19.23 get_meminfo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 766
54.19.24 get_next_selector_increment_value . . . . . . . . . . . . . . . . . . . . . 767
54.19.25 get_page_attributes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 768
54.19.26 get_page_size . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 768
54.19.27 get_pm_exception_handler . . . . . . . . . . . . . . . . . . . . . . . . . 768
54.19.28 get_pm_interrupt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 768
54.19.29 get_rm_callback . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 769
54.19.30 get_rm_interrupt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 773
54.19.31 get_run_mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 774
54.19.32 get_segment_base_address . . . . . . . . . . . . . . . . . . . . . . . . . 775
54.19.33 get_segment_limit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 775
54.19.34 get_ss . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 775
54.19.35 global_dos_alloc . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 776
54.19.36 global_dos_free . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 778
54.19.37 inportb . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 779
54.19.38 inportl . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 779
54.19.39 inportw . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 779
54.19.40 lock_code . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 780
54.19.41 lock_data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 780
54.19.42 lock_linear_region . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 780
54.19.43 map_device_in_memory_block . . . . . . . . . . . . . . . . . . . . . . . 781
54.19.44 outportb . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 781
47
CONTENTS
54.19.45 outportl . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 782
54.19.46 outportw . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 782
54.19.47 realintr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 782
54.19.48 request_linear_region . . . . . . . . . . . . . . . . . . . . . . . . . . . . 783
54.19.49 segment_to_descriptor . . . . . . . . . . . . . . . . . . . . . . . . . . . 784
54.19.50 seg_fillchar . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 784
54.19.51 seg_fillword . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 785
54.19.52 seg_move . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 786
54.19.53 set_descriptor_access_right . . . . . . . . . . . . . . . . . . . . . . . . . 786
54.19.54 set_exception_handler . . . . . . . . . . . . . . . . . . . . . . . . . . . . 786
54.19.55 set_page_attributes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 787
54.19.56 set_pm_exception_handler . . . . . . . . . . . . . . . . . . . . . . . . . 787
54.19.57 set_pm_interrupt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 787
54.19.58 set_rm_interrupt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 789
54.19.59 set_segment_base_address . . . . . . . . . . . . . . . . . . . . . . . . . 789
54.19.60 set_segment_limit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 789
54.19.61 tb_offset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 790
54.19.62 tb_segment . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 790
54.19.63 tb_size . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 790
54.19.64 transfer_buffer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 791
54.19.65 unlock_code . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 791
54.19.66 unlock_data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 791
54.19.67 unlock_linear_region . . . . . . . . . . . . . . . . . . . . . . . . . . . . 792
55 Reference for unit ’gpm’ 793
55.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 793
55.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 793
55.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 793
55.3.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 793
55.3.2 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 795
55.3.3 Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 797
55.4 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 798
55.4.1 Gpm_AnyDouble . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 798
55.4.2 Gpm_AnySingle . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 798
55.4.3 Gpm_AnyTriple . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 798
55.4.4 gpm_close . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 799
55.4.5 gpm_fitvalues . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 799
55.4.6 gpm_fitvaluesM . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 799
55.4.7 gpm_getevent . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 799
55.4.8 gpm_getsnapshot . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 801
48
CONTENTS
55.4.9 gpm_lowerroi . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 801
55.4.10 gpm_open . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 801
55.4.11 gpm_poproi . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 802
55.4.12 gpm_pushroi . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 802
55.4.13 gpm_raiseroi . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 802
55.4.14 gpm_repeat . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 802
55.4.15 Gpm_StrictDouble . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 803
55.4.16 Gpm_StrictSingle . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 803
55.4.17 Gpm_StrictTriple . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 803
56 Reference for unit ’Graph’ 804
56.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 804
56.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 804
56.3 Categorized functions: Text and font handling . . . . . . . . . . . . . . . . . . . . 804
56.4 Categorized functions: Filled drawings . . . . . . . . . . . . . . . . . . . . . . . . 805
56.5 Categorized functions: Drawing primitives . . . . . . . . . . . . . . . . . . . . . . 805
56.6 Categorized functions: Color management . . . . . . . . . . . . . . . . . . . . . . 806
56.7 Categorized functions: Screen management . . . . . . . . . . . . . . . . . . . . . . 806
56.8 Categorized functions: Initialization . . . . . . . . . . . . . . . . . . . . . . . . . . 807
56.9 Target specific issues: Linux . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 807
56.10 Target specific issues: DOS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 808
56.11 A word about mode selection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 808
56.12 Requirements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 813
56.13 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 813
56.13.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 813
56.13.2 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 830
56.13.3 Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 836
56.14 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 838
56.14.1 Arc . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 838
56.14.2 Bar . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 839
56.14.3 Bar3D . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 839
56.14.4 ClearDevice . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 839
56.14.5 Closegraph . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 839
56.14.6 DetectGraph . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 840
56.14.7 DrawPoly . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 840
56.14.8 Ellipse . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 840
56.14.9 FillEllipse . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 840
56.14.10 FillPoly . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 841
56.14.11 FloodFill . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 841
56.14.12 GetArcCoords . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 841
49
CONTENTS
56.14.13 GetAspectRatio . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 842
56.14.14 GetColor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 842
56.14.15 GetDefaultPalette . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 842
56.14.16 GetDirectVideo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 842
56.14.17 GetDriverName . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 843
56.14.18 GetFillPattern . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 843
56.14.19 GetFillSettings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 843
56.14.20 GetGraphMode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 843
56.14.21 GetLineSettings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 844
56.14.22 GetMaxColor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 844
56.14.23 GetMaxMode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 844
56.14.24 GetMaxX . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 844
56.14.25 GetMaxY . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 845
56.14.26 GetModeName . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 845
56.14.27 GetModeRange . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 845
56.14.28 GetPalette . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 845
56.14.29 GetPaletteSize . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 846
56.14.30 GetTextSettings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 846
56.14.31 GetViewSettings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 846
56.14.32 GetX . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 846
56.14.33 GetY . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 847
56.14.34 GraphDefaults . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 847
56.14.35 GraphErrorMsg . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 847
56.14.36 GraphResult . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 847
56.14.37 InitGraph . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 848
56.14.38 InstallUserDriver . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 848
56.14.39 InstallUserFont . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 849
56.14.40 LineRel . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 849
56.14.41 LineTo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 849
56.14.42 MoveRel . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 850
56.14.43 MoveTo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 850
56.14.44 OutText . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 850
56.14.45 PieSlice . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 850
56.14.46 queryadapterinfo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 851
56.14.47 Rectangle . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 851
56.14.48 RegisterBGIDriver . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 851
56.14.49 RegisterBGIfont . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 851
56.14.50 RestoreCrtMode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 852
56.14.51 Sector . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 852
56.14.52 SetAspectRatio . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 852
50
CONTENTS
56.14.53 SetColor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 852
56.14.54 SetDirectVideo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 853
56.14.55 SetFillPattern . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 853
56.14.56 SetFillStyle . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 853
56.14.57 SetGraphMode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 854
56.14.58 SetLineStyle . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 854
56.14.59 SetPalette . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 854
56.14.60 SetTextJustify . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 855
56.14.61 SetTextStyle . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 855
56.14.62 SetUserCharSize . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 856
56.14.63 SetViewPort . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 856
56.14.64 SetWriteMode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 856
56.14.65 TextHeight . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 857
56.14.66 TextWidth . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 857
57 Reference for unit ’heaptrc’ 858
57.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 858
57.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 858
57.3 Controlling HeapTrc with environment variables . . . . . . . . . . . . . . . . . . . 858
57.4 HeapTrc Usage . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 859
57.5 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 860
57.5.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 860
57.5.2 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 861
57.6 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 862
57.6.1 CheckPointer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 862
57.6.2 DumpHeap . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 862
57.6.3 SetHeapExtraInfo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 862
57.6.4 SetHeapTraceOutput . . . . . . . . . . . . . . . . . . . . . . . . . . . . 864
58 Reference for unit ’ipc’ 865
58.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 865
58.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 865
58.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 865
58.3.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 865
58.3.2 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 867
58.4 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 870
58.4.1 ftok . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 870
58.4.2 msgctl . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 870
58.4.3 msgget . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 873
58.4.4 msgrcv . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 873
58.4.5 msgsnd . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 874
51
CONTENTS
58.4.6 semctl . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 874
58.4.7 semget . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 879
58.4.8 semop . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 880
58.4.9 shmat . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 880
58.4.10 shmctl . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 881
58.4.11 shmdt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 883
58.4.12 shmget . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 883
59 Reference for unit ’keyboard’ 885
59.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 885
59.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 885
59.3 Unix specific notes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 885
59.4 Writing a keyboard driver . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 887
59.5 Keyboard scan codes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 890
59.6 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 892
59.6.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 892
59.6.2 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 897
59.7 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 898
59.7.1 DoneKeyboard . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 898
59.7.2 FunctionKeyName . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 898
59.7.3 GetKeyboardDriver . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 899
59.7.4 GetKeyEvent . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 899
59.7.5 GetKeyEventChar . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 900
59.7.6 GetKeyEventCode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 901
59.7.7 GetKeyEventFlags . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 901
59.7.8 GetKeyEventShiftState . . . . . . . . . . . . . . . . . . . . . . . . . . . 902
59.7.9 GetKeyEventUniCode . . . . . . . . . . . . . . . . . . . . . . . . . . . . 902
59.7.10 InitKeyboard . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 903
59.7.11 IsFunctionKey . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 903
59.7.12 KeyEventToString . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 904
59.7.13 KeyPressed . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 904
59.7.14 PollKeyEvent . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 904
59.7.15 PollShiftStateEvent . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 905
59.7.16 PutKeyEvent . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 906
59.7.17 SetKeyboardDriver . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 907
59.7.18 ShiftStateToString . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 907
59.7.19 TranslateKeyEvent . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 908
59.7.20 TranslateKeyEventUniCode . . . . . . . . . . . . . . . . . . . . . . . . . 908
60 Reference for unit ’lineinfo’ 909
60.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 909
52
CONTENTS
60.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 909
60.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 909
60.3.1 Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 909
60.4 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 909
60.4.1 CloseStabs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 909
60.4.2 GetLineInfo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 910
60.4.3 StabBackTraceStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 910
61 Reference for unit ’Linux’ 911
61.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 911
61.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 911
61.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 911
61.3.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 911
61.3.2 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 925
61.4 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 927
61.4.1 capget . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 927
61.4.2 capset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 928
61.4.3 clock_getres . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 928
61.4.4 clock_gettime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 928
61.4.5 clock_settime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 929
61.4.6 clone . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 929
61.4.7 epoll_create . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 931
61.4.8 epoll_ctl . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 931
61.4.9 epoll_wait . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 932
61.4.10 fdatasync . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 932
61.4.11 futex . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 932
61.4.12 futex_op . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 933
61.4.13 inotify_add_watch . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 934
61.4.14 inotify_init . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 934
61.4.15 inotify_init1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 935
61.4.16 inotify_rm_watch . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 935
61.4.17 sched_yield . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 935
61.4.18 setregid . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 935
61.4.19 setreuid . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 936
61.4.20 sync_file_range . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 936
61.4.21 Sysinfo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 936
62 Reference for unit ’lnfodwrf’ 938
62.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 938
62.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 938
62.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 938
53
CONTENTS
62.3.1 Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 938
62.4 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 938
62.4.1 CloseDwarf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 938
62.4.2 DwarfBackTraceStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 939
62.4.3 GetLineInfo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 939
63 Reference for unit ’math’ 940
63.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 940
63.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 940
63.3 Cash flow functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 940
63.4 Geometrical functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 941
63.5 Statistical functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 941
63.6 Number converting . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 942
63.7 Exponential and logarithmic functions . . . . . . . . . . . . . . . . . . . . . . . . 942
63.8 Hyperbolic functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 942
63.9 Trigoniometric functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 943
63.10 Angle unit conversion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 943
63.11 Min/max determination . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 943
63.12 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 944
63.12.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 944
63.12.2 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 945
63.13 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 946
63.13.1 arccos . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 946
63.13.2 arccosh . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 947
63.13.3 arcosh . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 947
63.13.4 arcsin . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 948
63.13.5 arcsinh . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 948
63.13.6 arctan2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 949
63.13.7 arctanh . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 949
63.13.8 arsinh . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 949
63.13.9 artanh . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 950
63.13.10 ceil . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 950
63.13.11 ceil64 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 951
63.13.12 ClearExceptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 951
63.13.13 CompareValue . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 951
63.13.14 cosecant . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 952
63.13.15 cosh . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 952
63.13.16 cot . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 953
63.13.17 cotan . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 953
63.13.18 csc . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 953
54
CONTENTS
63.13.19 cycletorad . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 954
63.13.20 DegNormalize . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 954
63.13.21 degtograd . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 954
63.13.22 degtorad . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 955
63.13.23 DivMod . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 955
63.13.24 EnsureRange . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 956
63.13.25 floor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 956
63.13.26 floor64 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 957
63.13.27 Frexp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 957
63.13.28 FutureValue . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 958
63.13.29 GetExceptionMask . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 958
63.13.30 GetPrecisionMode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 958
63.13.31 GetRoundMode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 958
63.13.32 gradtodeg . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 958
63.13.33 gradtorad . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 959
63.13.34 hypot . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 959
63.13.35 ifthen . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 960
63.13.36 InRange . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 960
63.13.37 InterestRate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 961
63.13.38 intpower . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 961
63.13.39 IsInfinite . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 962
63.13.40 IsNan . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 962
63.13.41 IsZero . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 962
63.13.42 ldexp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 962
63.13.43 lnxp1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 963
63.13.44 log10 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 963
63.13.45 log2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 964
63.13.46 logn . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 964
63.13.47 Max . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 965
63.13.48 MaxIntValue . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 966
63.13.49 maxvalue . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 966
63.13.50 mean . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 967
63.13.51 meanandstddev . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 968
63.13.52 Min . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 969
63.13.53 MinIntValue . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 970
63.13.54 minvalue . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 970
63.13.55 momentskewkurtosis . . . . . . . . . . . . . . . . . . . . . . . . . . . . 971
63.13.56 norm . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 972
63.13.57 NumberOfPeriods . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 973
63.13.58 Payment . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 973
55
CONTENTS
63.13.59 popnstddev . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 974
63.13.60 popnvariance . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 975
63.13.61 power . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 975
63.13.62 power(Float,Float):Float . . . . . . . . . . . . . . . . . . . . . . . . . . 976
63.13.63 power(Int64,Int64):Int64 . . . . . . . . . . . . . . . . . . . . . . . . . . 976
63.13.64 PresentValue . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 976
63.13.65 radtocycle . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 977
63.13.66 radtodeg . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 977
63.13.67 radtograd . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 978
63.13.68 randg . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 978
63.13.69 RandomFrom . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 979
63.13.70 RandomRange . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 979
63.13.71 RoundTo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 980
63.13.72 SameValue . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 980
63.13.73 sec . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 980
63.13.74 secant . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 981
63.13.75 SetExceptionMask . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 981
63.13.76 SetPrecisionMode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 981
63.13.77 SetRoundMode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 981
63.13.78 Sign . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 982
63.13.79 SimpleRoundTo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 982
63.13.80 sincos . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 982
63.13.81 sinh . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 983
63.13.82 stddev . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 983
63.13.83 sum . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 984
63.13.84 sumInt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 985
63.13.85 sumofsquares . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 985
63.13.86 sumsandsquares . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 986
63.13.87 tan . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 987
63.13.88 tanh . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 988
63.13.89 totalvariance . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 988
63.13.90 variance . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 989
63.14 EInvalidArgument . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 990
63.14.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 990
64 Reference for unit ’matrix’ 991
64.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 991
64.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 991
64.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 992
64.3.1 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 992
56
CONTENTS
64.4 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 994
64.4.1 add(Tmatrix2_double,Double):Tmatrix2_double . . . . . . . . . . . . . . 994
64.4.2 add(Tmatrix2_double,Tmatrix2_double):Tmatrix2_double . . . . . . . . 994
64.4.3 add(Tmatrix2_extended,extended):Tmatrix2_extended . . . . . . . . . . 995
64.4.4 add(Tmatrix2_extended,Tmatrix2_extended):Tmatrix2_extended . . . . . 995
64.4.5 add(Tmatrix2_single,single):Tmatrix2_single . . . . . . . . . . . . . . . 995
64.4.6 add(Tmatrix2_single,Tmatrix2_single):Tmatrix2_single . . . . . . . . . . 995
64.4.7 add(Tmatrix3_double,Double):Tmatrix3_double . . . . . . . . . . . . . . 995
64.4.8 add(Tmatrix3_double,Tmatrix3_double):Tmatrix3_double . . . . . . . . 996
64.4.9 add(Tmatrix3_extended,extended):Tmatrix3_extended . . . . . . . . . . 996
64.4.10 add(Tmatrix3_extended,Tmatrix3_extended):Tmatrix3_extended . . . . . 996
64.4.11 add(Tmatrix3_single,single):Tmatrix3_single . . . . . . . . . . . . . . . 996
64.4.12 add(Tmatrix3_single,Tmatrix3_single):Tmatrix3_single . . . . . . . . . . 996
64.4.13 add(Tmatrix4_double,Double):Tmatrix4_double . . . . . . . . . . . . . . 997
64.4.14 add(Tmatrix4_double,Tmatrix4_double):Tmatrix4_double . . . . . . . . 997
64.4.15 add(Tmatrix4_extended,extended):Tmatrix4_extended . . . . . . . . . . 997
64.4.16 add(Tmatrix4_extended,Tmatrix4_extended):Tmatrix4_extended . . . . . 997
64.4.17 add(Tmatrix4_single,single):Tmatrix4_single . . . . . . . . . . . . . . . 997
64.4.18 add(Tmatrix4_single,Tmatrix4_single):Tmatrix4_single . . . . . . . . . . 998
64.4.19 add(Tvector2_double,Double):Tvector2_double . . . . . . . . . . . . . . 998
64.4.20 add(Tvector2_double,Tvector2_double):Tvector2_double . . . . . . . . . 998
64.4.21 add(Tvector2_extended,extended):Tvector2_extended . . . . . . . . . . . 998
64.4.22 add(Tvector2_extended,Tvector2_extended):Tvector2_extended . . . . . 998
64.4.23 add(Tvector2_single,single):Tvector2_single . . . . . . . . . . . . . . . . 999
64.4.24 add(Tvector2_single,Tvector2_single):Tvector2_single . . . . . . . . . . 999
64.4.25 add(Tvector3_double,Double):Tvector3_double . . . . . . . . . . . . . . 999
64.4.26 add(Tvector3_double,Tvector3_double):Tvector3_double . . . . . . . . . 999
64.4.27 add(Tvector3_extended,extended):Tvector3_extended . . . . . . . . . . . 999
64.4.28 add(Tvector3_extended,Tvector3_extended):Tvector3_extended . . . . . 1000
64.4.29 add(Tvector3_single,single):Tvector3_single . . . . . . . . . . . . . . . . 1000
64.4.30 add(Tvector3_single,Tvector3_single):Tvector3_single . . . . . . . . . . 1000
64.4.31 add(Tvector4_double,Double):Tvector4_double . . . . . . . . . . . . . . 1000
64.4.32 add(Tvector4_double,Tvector4_double):Tvector4_double . . . . . . . . . 1000
64.4.33 add(Tvector4_extended,extended):Tvector4_extended . . . . . . . . . . . 1001
64.4.34 add(Tvector4_extended,Tvector4_extended):Tvector4_extended . . . . . 1001
64.4.35 add(Tvector4_single,single):Tvector4_single . . . . . . . . . . . . . . . . 1001
64.4.36 add(Tvector4_single,Tvector4_single):Tvector4_single . . . . . . . . . . 1001
64.4.37 assign(Tmatrix2_double):Tmatrix2_extended . . . . . . . . . . . . . . . 1001
64.4.38 assign(Tmatrix2_double):Tmatrix2_single . . . . . . . . . . . . . . . . . 1002
64.4.39 assign(Tmatrix2_double):Tmatrix3_double . . . . . . . . . . . . . . . . 1002
57
CONTENTS
64.4.40 assign(Tmatrix2_double):Tmatrix3_extended . . . . . . . . . . . . . . . 1002
64.4.41 assign(Tmatrix2_double):Tmatrix3_single . . . . . . . . . . . . . . . . . 1002
64.4.42 assign(Tmatrix2_double):Tmatrix4_double . . . . . . . . . . . . . . . . 1002
64.4.43 assign(Tmatrix2_double):Tmatrix4_extended . . . . . . . . . . . . . . . 1003
64.4.44 assign(Tmatrix2_double):Tmatrix4_single . . . . . . . . . . . . . . . . . 1003
64.4.45 assign(Tmatrix2_extended):Tmatrix2_double . . . . . . . . . . . . . . . 1003
64.4.46 assign(Tmatrix2_extended):Tmatrix2_single . . . . . . . . . . . . . . . . 1003
64.4.47 assign(Tmatrix2_extended):Tmatrix3_double . . . . . . . . . . . . . . . 1004
64.4.48 assign(Tmatrix2_extended):Tmatrix3_extended . . . . . . . . . . . . . . 1004
64.4.49 assign(Tmatrix2_extended):Tmatrix3_single . . . . . . . . . . . . . . . . 1004
64.4.50 assign(Tmatrix2_extended):Tmatrix4_double . . . . . . . . . . . . . . . 1004
64.4.51 assign(Tmatrix2_extended):Tmatrix4_extended . . . . . . . . . . . . . . 1005
64.4.52 assign(Tmatrix2_extended):Tmatrix4_single . . . . . . . . . . . . . . . . 1005
64.4.53 assign(Tmatrix2_single):Tmatrix2_double . . . . . . . . . . . . . . . . . 1005
64.4.54 assign(Tmatrix2_single):Tmatrix2_extended . . . . . . . . . . . . . . . . 1005
64.4.55 assign(Tmatrix2_single):Tmatrix3_double . . . . . . . . . . . . . . . . . 1005
64.4.56 assign(Tmatrix2_single):Tmatrix3_extended . . . . . . . . . . . . . . . . 1006
64.4.57 assign(Tmatrix2_single):Tmatrix3_single . . . . . . . . . . . . . . . . . 1006
64.4.58 assign(Tmatrix2_single):Tmatrix4_double . . . . . . . . . . . . . . . . . 1006
64.4.59 assign(Tmatrix2_single):Tmatrix4_extended . . . . . . . . . . . . . . . . 1006
64.4.60 assign(Tmatrix2_single):Tmatrix4_single . . . . . . . . . . . . . . . . . 1006
64.4.61 assign(Tmatrix3_double):Tmatrix2_double . . . . . . . . . . . . . . . . 1007
64.4.62 assign(Tmatrix3_double):Tmatrix2_extended . . . . . . . . . . . . . . . 1007
64.4.63 assign(Tmatrix3_double):Tmatrix2_single . . . . . . . . . . . . . . . . . 1007
64.4.64 assign(Tmatrix3_double):Tmatrix3_extended . . . . . . . . . . . . . . . 1007
64.4.65 assign(Tmatrix3_double):Tmatrix3_single . . . . . . . . . . . . . . . . . 1007
64.4.66 assign(Tmatrix3_double):Tmatrix4_double . . . . . . . . . . . . . . . . 1008
64.4.67 assign(Tmatrix3_double):Tmatrix4_extended . . . . . . . . . . . . . . . 1008
64.4.68 assign(Tmatrix3_double):Tmatrix4_single . . . . . . . . . . . . . . . . . 1008
64.4.69 assign(Tmatrix3_extended):Tmatrix2_double . . . . . . . . . . . . . . . 1008
64.4.70 assign(Tmatrix3_extended):Tmatrix2_extended . . . . . . . . . . . . . . 1009
64.4.71 assign(Tmatrix3_extended):Tmatrix2_single . . . . . . . . . . . . . . . . 1009
64.4.72 assign(Tmatrix3_extended):Tmatrix3_double . . . . . . . . . . . . . . . 1009
64.4.73 assign(Tmatrix3_extended):Tmatrix3_single . . . . . . . . . . . . . . . . 1009
64.4.74 assign(Tmatrix3_extended):Tmatrix4_double . . . . . . . . . . . . . . . 1010
64.4.75 assign(Tmatrix3_extended):Tmatrix4_extended . . . . . . . . . . . . . . 1010
64.4.76 assign(Tmatrix3_extended):Tmatrix4_single . . . . . . . . . . . . . . . . 1010
64.4.77 assign(Tmatrix3_single):Tmatrix2_double . . . . . . . . . . . . . . . . . 1010
64.4.78 assign(Tmatrix3_single):Tmatrix2_extended . . . . . . . . . . . . . . . . 1010
64.4.79 assign(Tmatrix3_single):Tmatrix2_single . . . . . . . . . . . . . . . . . 1011
58
CONTENTS
64.4.80 assign(Tmatrix3_single):Tmatrix3_double . . . . . . . . . . . . . . . . . 1011
64.4.81 assign(Tmatrix3_single):Tmatrix3_extended . . . . . . . . . . . . . . . . 1011
64.4.82 assign(Tmatrix3_single):Tmatrix4_double . . . . . . . . . . . . . . . . . 1011
64.4.83 assign(Tmatrix3_single):Tmatrix4_extended . . . . . . . . . . . . . . . . 1012
64.4.84 assign(Tmatrix3_single):Tmatrix4_single . . . . . . . . . . . . . . . . . 1012
64.4.85 assign(Tmatrix4_double):Tmatrix2_double . . . . . . . . . . . . . . . . 1012
64.4.86 assign(Tmatrix4_double):Tmatrix2_extended . . . . . . . . . . . . . . . 1012
64.4.87 assign(Tmatrix4_double):Tmatrix2_single . . . . . . . . . . . . . . . . . 1012
64.4.88 assign(Tmatrix4_double):Tmatrix3_double . . . . . . . . . . . . . . . . 1013
64.4.89 assign(Tmatrix4_double):Tmatrix3_extended . . . . . . . . . . . . . . . 1013
64.4.90 assign(Tmatrix4_double):Tmatrix3_single . . . . . . . . . . . . . . . . . 1013
64.4.91 assign(Tmatrix4_double):Tmatrix4_extended . . . . . . . . . . . . . . . 1013
64.4.92 assign(Tmatrix4_double):Tmatrix4_single . . . . . . . . . . . . . . . . . 1013
64.4.93 assign(Tmatrix4_extended):Tmatrix2_double . . . . . . . . . . . . . . . 1014
64.4.94 assign(Tmatrix4_extended):Tmatrix2_extended . . . . . . . . . . . . . . 1014
64.4.95 assign(Tmatrix4_extended):Tmatrix2_single . . . . . . . . . . . . . . . . 1014
64.4.96 assign(Tmatrix4_extended):Tmatrix3_double . . . . . . . . . . . . . . . 1014
64.4.97 assign(Tmatrix4_extended):Tmatrix3_extended . . . . . . . . . . . . . . 1015
64.4.98 assign(Tmatrix4_extended):Tmatrix3_single . . . . . . . . . . . . . . . . 1015
64.4.99 assign(Tmatrix4_extended):Tmatrix4_double . . . . . . . . . . . . . . . 1015
64.4.100 assign(Tmatrix4_extended):Tmatrix4_single . . . . . . . . . . . . . . . . 1015
64.4.101 assign(Tmatrix4_single):Tmatrix2_double . . . . . . . . . . . . . . . . . 1015
64.4.102 assign(Tmatrix4_single):Tmatrix2_extended . . . . . . . . . . . . . . . . 1016
64.4.103 assign(Tmatrix4_single):Tmatrix2_single . . . . . . . . . . . . . . . . . 1016
64.4.104 assign(Tmatrix4_single):Tmatrix3_double . . . . . . . . . . . . . . . . . 1016
64.4.105 assign(Tmatrix4_single):Tmatrix3_extended . . . . . . . . . . . . . . . . 1016
64.4.106 assign(Tmatrix4_single):Tmatrix3_single . . . . . . . . . . . . . . . . . 1017
64.4.107 assign(Tmatrix4_single):Tmatrix4_double . . . . . . . . . . . . . . . . . 1017
64.4.108 assign(Tmatrix4_single):Tmatrix4_extended . . . . . . . . . . . . . . . . 1017
64.4.109 assign(Tvector2_double):Tvector2_extended . . . . . . . . . . . . . . . . 1017
64.4.110 assign(Tvector2_double):Tvector2_single . . . . . . . . . . . . . . . . . 1017
64.4.111 assign(Tvector2_double):Tvector3_double . . . . . . . . . . . . . . . . . 1018
64.4.112 assign(Tvector2_double):Tvector3_extended . . . . . . . . . . . . . . . . 1018
64.4.113 assign(Tvector2_double):Tvector3_single . . . . . . . . . . . . . . . . . 1018
64.4.114 assign(Tvector2_double):Tvector4_double . . . . . . . . . . . . . . . . . 1018
64.4.115 assign(Tvector2_double):Tvector4_extended . . . . . . . . . . . . . . . . 1018
64.4.116 assign(Tvector2_double):Tvector4_single . . . . . . . . . . . . . . . . . 1019
64.4.117 assign(Tvector2_extended):Tvector2_double . . . . . . . . . . . . . . . . 1019
64.4.118 assign(Tvector2_extended):Tvector2_single . . . . . . . . . . . . . . . . 1019
64.4.119 assign(Tvector2_extended):Tvector3_double . . . . . . . . . . . . . . . . 1019
59
CONTENTS
64.4.120 assign(Tvector2_extended):Tvector3_extended . . . . . . . . . . . . . . 1020
64.4.121 assign(Tvector2_extended):Tvector3_single . . . . . . . . . . . . . . . . 1020
64.4.122 assign(Tvector2_extended):Tvector4_double . . . . . . . . . . . . . . . . 1020
64.4.123 assign(Tvector2_extended):Tvector4_extended . . . . . . . . . . . . . . 1020
64.4.124 assign(Tvector2_extended):Tvector4_single . . . . . . . . . . . . . . . . 1021
64.4.125 assign(Tvector2_single):Tvector2_double . . . . . . . . . . . . . . . . . 1021
64.4.126 assign(Tvector2_single):Tvector2_extended . . . . . . . . . . . . . . . . 1021
64.4.127 assign(Tvector2_single):Tvector3_double . . . . . . . . . . . . . . . . . 1021
64.4.128 assign(Tvector2_single):Tvector3_extended . . . . . . . . . . . . . . . . 1021
64.4.129 assign(Tvector2_single):Tvector3_single . . . . . . . . . . . . . . . . . . 1022
64.4.130 assign(Tvector2_single):Tvector4_double . . . . . . . . . . . . . . . . . 1022
64.4.131 assign(Tvector2_single):Tvector4_extended . . . . . . . . . . . . . . . . 1022
64.4.132 assign(Tvector2_single):Tvector4_single . . . . . . . . . . . . . . . . . . 1022
64.4.133 assign(Tvector3_double):Tvector2_double . . . . . . . . . . . . . . . . . 1023
64.4.134 assign(Tvector3_double):Tvector2_extended . . . . . . . . . . . . . . . . 1023
64.4.135 assign(Tvector3_double):Tvector2_single . . . . . . . . . . . . . . . . . 1023
64.4.136 assign(Tvector3_double):Tvector3_extended . . . . . . . . . . . . . . . . 1023
64.4.137 assign(Tvector3_double):Tvector3_single . . . . . . . . . . . . . . . . . 1023
64.4.138 assign(Tvector3_double):Tvector4_double . . . . . . . . . . . . . . . . . 1024
64.4.139 assign(Tvector3_double):Tvector4_extended . . . . . . . . . . . . . . . . 1024
64.4.140 assign(Tvector3_double):Tvector4_single . . . . . . . . . . . . . . . . . 1024
64.4.141 assign(Tvector3_extended):Tvector2_double . . . . . . . . . . . . . . . . 1024
64.4.142 assign(Tvector3_extended):Tvector2_extended . . . . . . . . . . . . . . 1025
64.4.143 assign(Tvector3_extended):Tvector2_single . . . . . . . . . . . . . . . . 1025
64.4.144 assign(Tvector3_extended):Tvector3_double . . . . . . . . . . . . . . . . 1025
64.4.145 assign(Tvector3_extended):Tvector3_single . . . . . . . . . . . . . . . . 1025
64.4.146 assign(Tvector3_extended):Tvector4_double . . . . . . . . . . . . . . . . 1026
64.4.147 assign(Tvector3_extended):Tvector4_extended . . . . . . . . . . . . . . 1026
64.4.148 assign(Tvector3_extended):Tvector4_single . . . . . . . . . . . . . . . . 1026
64.4.149 assign(Tvector3_single):Tvector2_double . . . . . . . . . . . . . . . . . 1026
64.4.150 assign(Tvector3_single):Tvector2_extended . . . . . . . . . . . . . . . . 1026
64.4.151 assign(Tvector3_single):Tvector2_single . . . . . . . . . . . . . . . . . . 1027
64.4.152 assign(Tvector3_single):Tvector3_double . . . . . . . . . . . . . . . . . 1027
64.4.153 assign(Tvector3_single):Tvector3_extended . . . . . . . . . . . . . . . . 1027
64.4.154 assign(Tvector3_single):Tvector4_double . . . . . . . . . . . . . . . . . 1027
64.4.155 assign(Tvector3_single):Tvector4_extended . . . . . . . . . . . . . . . . 1028
64.4.156 assign(Tvector3_single):Tvector4_single . . . . . . . . . . . . . . . . . . 1028
64.4.157 assign(Tvector4_double):Tvector2_double . . . . . . . . . . . . . . . . . 1028
64.4.158 assign(Tvector4_double):Tvector2_extended . . . . . . . . . . . . . . . . 1028
64.4.159 assign(Tvector4_double):Tvector2_single . . . . . . . . . . . . . . . . . 1028
60
CONTENTS
64.4.160 assign(Tvector4_double):Tvector3_double . . . . . . . . . . . . . . . . . 1029
64.4.161 assign(Tvector4_double):Tvector3_extended . . . . . . . . . . . . . . . . 1029
64.4.162 assign(Tvector4_double):Tvector3_single . . . . . . . . . . . . . . . . . 1029
64.4.163 assign(Tvector4_double):Tvector4_extended . . . . . . . . . . . . . . . . 1029
64.4.164 assign(Tvector4_double):Tvector4_single . . . . . . . . . . . . . . . . . 1030
64.4.165 assign(Tvector4_extended):Tvector2_double . . . . . . . . . . . . . . . . 1030
64.4.166 assign(Tvector4_extended):Tvector2_extended . . . . . . . . . . . . . . 1030
64.4.167 assign(Tvector4_extended):Tvector2_single . . . . . . . . . . . . . . . . 1030
64.4.168 assign(Tvector4_extended):Tvector3_double . . . . . . . . . . . . . . . . 1031
64.4.169 assign(Tvector4_extended):Tvector3_extended . . . . . . . . . . . . . . 1031
64.4.170 assign(Tvector4_extended):Tvector3_single . . . . . . . . . . . . . . . . 1031
64.4.171 assign(Tvector4_extended):Tvector4_double . . . . . . . . . . . . . . . . 1031
64.4.172 assign(Tvector4_extended):Tvector4_single . . . . . . . . . . . . . . . . 1032
64.4.173 assign(Tvector4_single):Tvector2_double . . . . . . . . . . . . . . . . . 1032
64.4.174 assign(Tvector4_single):Tvector2_extended . . . . . . . . . . . . . . . . 1032
64.4.175 assign(Tvector4_single):Tvector2_single . . . . . . . . . . . . . . . . . . 1032
64.4.176 assign(Tvector4_single):Tvector3_double . . . . . . . . . . . . . . . . . 1033
64.4.177 assign(Tvector4_single):Tvector3_extended . . . . . . . . . . . . . . . . 1033
64.4.178 assign(Tvector4_single):Tvector3_single . . . . . . . . . . . . . . . . . . 1033
64.4.179 assign(Tvector4_single):Tvector4_double . . . . . . . . . . . . . . . . . 1033
64.4.180 assign(Tvector4_single):Tvector4_extended . . . . . . . . . . . . . . . . 1033
64.4.181 divide(Tmatrix2_double,Double):Tmatrix2_double . . . . . . . . . . . . 1034
64.4.182 divide(Tmatrix2_extended,extended):Tmatrix2_extended . . . . . . . . . 1034
64.4.183 divide(Tmatrix2_single,single):Tmatrix2_single . . . . . . . . . . . . . . 1034
64.4.184 divide(Tmatrix3_double,Double):Tmatrix3_double . . . . . . . . . . . . 1034
64.4.185 divide(Tmatrix3_extended,extended):Tmatrix3_extended . . . . . . . . . 1034
64.4.186 divide(Tmatrix3_single,single):Tmatrix3_single . . . . . . . . . . . . . . 1035
64.4.187 divide(Tmatrix4_double,Double):Tmatrix4_double . . . . . . . . . . . . 1035
64.4.188 divide(Tmatrix4_extended,extended):Tmatrix4_extended . . . . . . . . . 1035
64.4.189 divide(Tmatrix4_single,single):Tmatrix4_single . . . . . . . . . . . . . . 1035
64.4.190 divide(Tvector2_double,Double):Tvector2_double . . . . . . . . . . . . . 1035
64.4.191 divide(Tvector2_extended,extended):Tvector2_extended . . . . . . . . . 1036
64.4.192 divide(Tvector2_single,single):Tvector2_single . . . . . . . . . . . . . . 1036
64.4.193 divide(Tvector3_double,Double):Tvector3_double . . . . . . . . . . . . . 1036
64.4.194 divide(Tvector3_extended,extended):Tvector3_extended . . . . . . . . . 1036
64.4.195 divide(Tvector3_single,single):Tvector3_single . . . . . . . . . . . . . . 1036
64.4.196 divide(Tvector4_double,Double):Tvector4_double . . . . . . . . . . . . . 1037
64.4.197 divide(Tvector4_extended,extended):Tvector4_extended . . . . . . . . . 1037
64.4.198 divide(Tvector4_single,single):Tvector4_single . . . . . . . . . . . . . . 1037
64.4.199 multiply(Tmatrix2_double,Double):Tmatrix2_double . . . . . . . . . . . 1037
61
CONTENTS
64.4.200 multiply(Tmatrix2_double,Tmatrix2_double):Tmatrix2_double . . . . . . 1037
64.4.201 multiply(Tmatrix2_double,Tvector2_double):Tvector2_double . . . . . . 1038
64.4.202 multiply(Tmatrix2_extended,extended):Tmatrix2_extended . . . . . . . . 1038
64.4.203 multiply(Tmatrix2_extended,Tmatrix2_extended):Tmatrix2_extended . . 1038
64.4.204 multiply(Tmatrix2_extended,Tvector2_extended):Tvector2_extended . . . 1038
64.4.205 multiply(Tmatrix2_single,single):Tmatrix2_single . . . . . . . . . . . . . 1039
64.4.206 multiply(Tmatrix2_single,Tmatrix2_single):Tmatrix2_single . . . . . . . 1039
64.4.207 multiply(Tmatrix2_single,Tvector2_single):Tvector2_single . . . . . . . 1039
64.4.208 multiply(Tmatrix3_double,Double):Tmatrix3_double . . . . . . . . . . . 1039
64.4.209 multiply(Tmatrix3_double,Tmatrix3_double):Tmatrix3_double . . . . . . 1039
64.4.210 multiply(Tmatrix3_double,Tvector3_double):Tvector3_double . . . . . . 1040
64.4.211 multiply(Tmatrix3_extended,extended):Tmatrix3_extended . . . . . . . . 1040
64.4.212 multiply(Tmatrix3_extended,Tmatrix3_extended):Tmatrix3_extended . . 1040
64.4.213 multiply(Tmatrix3_extended,Tvector3_extended):Tvector3_extended . . . 1040
64.4.214 multiply(Tmatrix3_single,single):Tmatrix3_single . . . . . . . . . . . . . 1041
64.4.215 multiply(Tmatrix3_single,Tmatrix3_single):Tmatrix3_single . . . . . . . 1041
64.4.216 multiply(Tmatrix3_single,Tvector3_single):Tvector3_single . . . . . . . 1041
64.4.217 multiply(Tmatrix4_double,Double):Tmatrix4_double . . . . . . . . . . . 1041
64.4.218 multiply(Tmatrix4_double,Tmatrix4_double):Tmatrix4_double . . . . . . 1041
64.4.219 multiply(Tmatrix4_double,Tvector4_double):Tvector4_double . . . . . . 1042
64.4.220 multiply(Tmatrix4_extended,extended):Tmatrix4_extended . . . . . . . . 1042
64.4.221 multiply(Tmatrix4_extended,Tmatrix4_extended):Tmatrix4_extended . . 1042
64.4.222 multiply(Tmatrix4_extended,Tvector4_extended):Tvector4_extended . . . 1042
64.4.223 multiply(Tmatrix4_single,single):Tmatrix4_single . . . . . . . . . . . . . 1043
64.4.224 multiply(Tmatrix4_single,Tmatrix4_single):Tmatrix4_single . . . . . . . 1043
64.4.225 multiply(Tmatrix4_single,Tvector4_single):Tvector4_single . . . . . . . 1043
64.4.226 multiply(Tvector2_double,Double):Tvector2_double . . . . . . . . . . . 1043
64.4.227 multiply(Tvector2_double,Tvector2_double):Tvector2_double . . . . . . 1043
64.4.228 multiply(Tvector2_extended,extended):Tvector2_extended . . . . . . . . 1044
64.4.229 multiply(Tvector2_extended,Tvector2_extended):Tvector2_extended . . . 1044
64.4.230 multiply(Tvector2_single,single):Tvector2_single . . . . . . . . . . . . . 1044
64.4.231 multiply(Tvector2_single,Tvector2_single):Tvector2_single . . . . . . . . 1044
64.4.232 multiply(Tvector3_double,Double):Tvector3_double . . . . . . . . . . . 1044
64.4.233 multiply(Tvector3_double,Tvector3_double):Tvector3_double . . . . . . 1045
64.4.234 multiply(Tvector3_extended,extended):Tvector3_extended . . . . . . . . 1045
64.4.235 multiply(Tvector3_extended,Tvector3_extended):Tvector3_extended . . . 1045
64.4.236 multiply(Tvector3_single,single):Tvector3_single . . . . . . . . . . . . . 1045
64.4.237 multiply(Tvector3_single,Tvector3_single):Tvector3_single . . . . . . . . 1045
64.4.238 multiply(Tvector4_double,Double):Tvector4_double . . . . . . . . . . . 1046
64.4.239 multiply(Tvector4_double,Tvector4_double):Tvector4_double . . . . . . 1046
62
CONTENTS
64.4.240 multiply(Tvector4_extended,extended):Tvector4_extended . . . . . . . . 1046
64.4.241 multiply(Tvector4_extended,Tvector4_extended):Tvector4_extended . . . 1046
64.4.242 multiply(Tvector4_single,single):Tvector4_single . . . . . . . . . . . . . 1046
64.4.243 multiply(Tvector4_single,Tvector4_single):Tvector4_single . . . . . . . . 1047
64.4.244 negative(Tmatrix2_double):Tmatrix2_double . . . . . . . . . . . . . . . 1047
64.4.245 negative(Tmatrix2_extended):Tmatrix2_extended . . . . . . . . . . . . . 1047
64.4.246 negative(Tmatrix2_single):Tmatrix2_single . . . . . . . . . . . . . . . . 1047
64.4.247 negative(Tmatrix3_double):Tmatrix3_double . . . . . . . . . . . . . . . 1047
64.4.248 negative(Tmatrix3_extended):Tmatrix3_extended . . . . . . . . . . . . . 1048
64.4.249 negative(Tmatrix3_single):Tmatrix3_single . . . . . . . . . . . . . . . . 1048
64.4.250 negative(Tmatrix4_double):Tmatrix4_double . . . . . . . . . . . . . . . 1048
64.4.251 negative(Tmatrix4_extended):Tmatrix4_extended . . . . . . . . . . . . . 1048
64.4.252 negative(Tmatrix4_single):Tmatrix4_single . . . . . . . . . . . . . . . . 1048
64.4.253 negative(Tvector2_double):Tvector2_double . . . . . . . . . . . . . . . . 1048
64.4.254 negative(Tvector2_extended):Tvector2_extended . . . . . . . . . . . . . 1049
64.4.255 negative(Tvector2_single):Tvector2_single . . . . . . . . . . . . . . . . . 1049
64.4.256 negative(Tvector3_double):Tvector3_double . . . . . . . . . . . . . . . . 1049
64.4.257 negative(Tvector3_extended):Tvector3_extended . . . . . . . . . . . . . 1049
64.4.258 negative(Tvector3_single):Tvector3_single . . . . . . . . . . . . . . . . . 1049
64.4.259 negative(Tvector4_double):Tvector4_double . . . . . . . . . . . . . . . . 1050
64.4.260 negative(Tvector4_extended):Tvector4_extended . . . . . . . . . . . . . 1050
64.4.261 negative(Tvector4_single):Tvector4_single . . . . . . . . . . . . . . . . . 1050
64.4.262 power(Tvector2_double,Tvector2_double):Double . . . . . . . . . . . . . 1050
64.4.263 power(Tvector2_extended,Tvector2_extended):extended . . . . . . . . . 1050
64.4.264 power(Tvector2_single,Tvector2_single):single . . . . . . . . . . . . . . 1051
64.4.265 power(Tvector3_double,Tvector3_double):Double . . . . . . . . . . . . . 1051
64.4.266 power(Tvector3_extended,Tvector3_extended):extended . . . . . . . . . 1051
64.4.267 power(Tvector3_single,Tvector3_single):single . . . . . . . . . . . . . . 1051
64.4.268 power(Tvector4_double,Tvector4_double):Double . . . . . . . . . . . . . 1051
64.4.269 power(Tvector4_extended,Tvector4_extended):extended . . . . . . . . . 1052
64.4.270 power(Tvector4_single,Tvector4_single):single . . . . . . . . . . . . . . 1052
64.4.271 subtract(Tmatrix2_double,Double):Tmatrix2_double . . . . . . . . . . . 1052
64.4.272 subtract(Tmatrix2_double,Tmatrix2_double):Tmatrix2_double . . . . . . 1052
64.4.273 subtract(Tmatrix2_extended,extended):Tmatrix2_extended . . . . . . . . 1052
64.4.274 subtract(Tmatrix2_extended,Tmatrix2_extended):Tmatrix2_extended . . 1053
64.4.275 subtract(Tmatrix2_single,single):Tmatrix2_single . . . . . . . . . . . . . 1053
64.4.276 subtract(Tmatrix2_single,Tmatrix2_single):Tmatrix2_single . . . . . . . 1053
64.4.277 subtract(Tmatrix3_double,Double):Tmatrix3_double . . . . . . . . . . . 1053
64.4.278 subtract(Tmatrix3_double,Tmatrix3_double):Tmatrix3_double . . . . . . 1053
64.4.279 subtract(Tmatrix3_extended,extended):Tmatrix3_extended . . . . . . . . 1054
63
CONTENTS
64.4.280 subtract(Tmatrix3_extended,Tmatrix3_extended):Tmatrix3_extended . . 1054
64.4.281 subtract(Tmatrix3_single,single):Tmatrix3_single . . . . . . . . . . . . . 1054
64.4.282 subtract(Tmatrix3_single,Tmatrix3_single):Tmatrix3_single . . . . . . . 1054
64.4.283 subtract(Tmatrix4_double,Double):Tmatrix4_double . . . . . . . . . . . 1054
64.4.284 subtract(Tmatrix4_double,Tmatrix4_double):Tmatrix4_double . . . . . . 1055
64.4.285 subtract(Tmatrix4_extended,extended):Tmatrix4_extended . . . . . . . . 1055
64.4.286 subtract(Tmatrix4_extended,Tmatrix4_extended):Tmatrix4_extended . . 1055
64.4.287 subtract(Tmatrix4_single,single):Tmatrix4_single . . . . . . . . . . . . . 1055
64.4.288 subtract(Tmatrix4_single,Tmatrix4_single):Tmatrix4_single . . . . . . . 1055
64.4.289 subtract(Tvector2_double,Double):Tvector2_double . . . . . . . . . . . . 1056
64.4.290 subtract(Tvector2_double,Tvector2_double):Tvector2_double . . . . . . 1056
64.4.291 subtract(Tvector2_extended,extended):Tvector2_extended . . . . . . . . 1056
64.4.292 subtract(Tvector2_extended,Tvector2_extended):Tvector2_extended . . . 1056
64.4.293 subtract(Tvector2_single,single):Tvector2_single . . . . . . . . . . . . . 1056
64.4.294 subtract(Tvector2_single,Tvector2_single):Tvector2_single . . . . . . . . 1057
64.4.295 subtract(Tvector3_double,Double):Tvector3_double . . . . . . . . . . . . 1057
64.4.296 subtract(Tvector3_double,Tvector3_double):Tvector3_double . . . . . . 1057
64.4.297 subtract(Tvector3_extended,extended):Tvector3_extended . . . . . . . . 1057
64.4.298 subtract(Tvector3_extended,Tvector3_extended):Tvector3_extended . . . 1057
64.4.299 subtract(Tvector3_single,single):Tvector3_single . . . . . . . . . . . . . 1058
64.4.300 subtract(Tvector3_single,Tvector3_single):Tvector3_single . . . . . . . . 1058
64.4.301 subtract(Tvector4_double,Double):Tvector4_double . . . . . . . . . . . . 1058
64.4.302 subtract(Tvector4_double,Tvector4_double):Tvector4_double . . . . . . 1058
64.4.303 subtract(Tvector4_extended,extended):Tvector4_extended . . . . . . . . 1058
64.4.304 subtract(Tvector4_extended,Tvector4_extended):Tvector4_extended . . . 1059
64.4.305 subtract(Tvector4_single,single):Tvector4_single . . . . . . . . . . . . . 1059
64.4.306 subtract(Tvector4_single,Tvector4_single):Tvector4_single . . . . . . . . 1059
64.4.307 symmetricaldifference(Tvector3_double,Tvector3_double):Tvector3_double1059
64.4.308 symmetricaldifference(Tvector3_extended,Tvector3_extended):Tvector3_extended1060
64.4.309 symmetricaldifference(Tvector3_single,Tvector3_single):Tvector3_single 1060
64.5 Tmatrix2_double . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1060
64.5.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1060
64.5.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1060
64.5.3 Tmatrix2_double.init_zero . . . . . . . . . . . . . . . . . . . . . . . . . 1061
64.5.4 Tmatrix2_double.init_identity . . . . . . . . . . . . . . . . . . . . . . . 1061
64.5.5 Tmatrix2_double.init . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1061
64.5.6 Tmatrix2_double.get_column . . . . . . . . . . . . . . . . . . . . . . . . 1061
64.5.7 Tmatrix2_double.get_row . . . . . . . . . . . . . . . . . . . . . . . . . . 1061
64.5.8 Tmatrix2_double.set_column . . . . . . . . . . . . . . . . . . . . . . . . 1061
64.5.9 Tmatrix2_double.set_row . . . . . . . . . . . . . . . . . . . . . . . . . . 1062
64
CONTENTS
64.5.10 Tmatrix2_double.determinant . . . . . . . . . . . . . . . . . . . . . . . . 1062
64.5.11 Tmatrix2_double.inverse . . . . . . . . . . . . . . . . . . . . . . . . . . 1062
64.5.12 Tmatrix2_double.transpose . . . . . . . . . . . . . . . . . . . . . . . . . 1062
64.6 Tmatrix2_extended . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1062
64.6.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1062
64.6.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1063
64.6.3 Tmatrix2_extended.init_zero . . . . . . . . . . . . . . . . . . . . . . . . 1063
64.6.4 Tmatrix2_extended.init_identity . . . . . . . . . . . . . . . . . . . . . . 1063
64.6.5 Tmatrix2_extended.init . . . . . . . . . . . . . . . . . . . . . . . . . . . 1063
64.6.6 Tmatrix2_extended.get_column . . . . . . . . . . . . . . . . . . . . . . . 1063
64.6.7 Tmatrix2_extended.get_row . . . . . . . . . . . . . . . . . . . . . . . . 1064
64.6.8 Tmatrix2_extended.set_column . . . . . . . . . . . . . . . . . . . . . . . 1064
64.6.9 Tmatrix2_extended.set_row . . . . . . . . . . . . . . . . . . . . . . . . . 1064
64.6.10 Tmatrix2_extended.determinant . . . . . . . . . . . . . . . . . . . . . . 1064
64.6.11 Tmatrix2_extended.inverse . . . . . . . . . . . . . . . . . . . . . . . . . 1064
64.6.12 Tmatrix2_extended.transpose . . . . . . . . . . . . . . . . . . . . . . . . 1064
64.7 Tmatrix2_single . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1065
64.7.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1065
64.7.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1065
64.7.3 Tmatrix2_single.init_zero . . . . . . . . . . . . . . . . . . . . . . . . . . 1065
64.7.4 Tmatrix2_single.init_identity . . . . . . . . . . . . . . . . . . . . . . . . 1065
64.7.5 Tmatrix2_single.init . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1065
64.7.6 Tmatrix2_single.get_column . . . . . . . . . . . . . . . . . . . . . . . . 1066
64.7.7 Tmatrix2_single.get_row . . . . . . . . . . . . . . . . . . . . . . . . . . 1066
64.7.8 Tmatrix2_single.set_column . . . . . . . . . . . . . . . . . . . . . . . . 1066
64.7.9 Tmatrix2_single.set_row . . . . . . . . . . . . . . . . . . . . . . . . . . 1066
64.7.10 Tmatrix2_single.determinant . . . . . . . . . . . . . . . . . . . . . . . . 1066
64.7.11 Tmatrix2_single.inverse . . . . . . . . . . . . . . . . . . . . . . . . . . . 1066
64.7.12 Tmatrix2_single.transpose . . . . . . . . . . . . . . . . . . . . . . . . . 1067
64.8 Tmatrix3_double . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1067
64.8.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1067
64.8.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1067
64.8.3 Tmatrix3_double.init_zero . . . . . . . . . . . . . . . . . . . . . . . . . 1067
64.8.4 Tmatrix3_double.init_identity . . . . . . . . . . . . . . . . . . . . . . . 1067
64.8.5 Tmatrix3_double.init . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1068
64.8.6 Tmatrix3_double.get_column . . . . . . . . . . . . . . . . . . . . . . . . 1068
64.8.7 Tmatrix3_double.get_row . . . . . . . . . . . . . . . . . . . . . . . . . . 1068
64.8.8 Tmatrix3_double.set_column . . . . . . . . . . . . . . . . . . . . . . . . 1068
64.8.9 Tmatrix3_double.set_row . . . . . . . . . . . . . . . . . . . . . . . . . . 1068
64.8.10 Tmatrix3_double.determinant . . . . . . . . . . . . . . . . . . . . . . . . 1069
65
CONTENTS
64.8.11 Tmatrix3_double.inverse . . . . . . . . . . . . . . . . . . . . . . . . . . 1069
64.8.12 Tmatrix3_double.transpose . . . . . . . . . . . . . . . . . . . . . . . . . 1069
64.9 Tmatrix3_extended . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1069
64.9.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1069
64.9.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1069
64.9.3 Tmatrix3_extended.init_zero . . . . . . . . . . . . . . . . . . . . . . . . 1070
64.9.4 Tmatrix3_extended.init_identity . . . . . . . . . . . . . . . . . . . . . . 1070
64.9.5 Tmatrix3_extended.init . . . . . . . . . . . . . . . . . . . . . . . . . . . 1070
64.9.6 Tmatrix3_extended.get_column . . . . . . . . . . . . . . . . . . . . . . . 1070
64.9.7 Tmatrix3_extended.get_row . . . . . . . . . . . . . . . . . . . . . . . . 1070
64.9.8 Tmatrix3_extended.set_column . . . . . . . . . . . . . . . . . . . . . . . 1071
64.9.9 Tmatrix3_extended.set_row . . . . . . . . . . . . . . . . . . . . . . . . . 1071
64.9.10 Tmatrix3_extended.determinant . . . . . . . . . . . . . . . . . . . . . . 1071
64.9.11 Tmatrix3_extended.inverse . . . . . . . . . . . . . . . . . . . . . . . . . 1071
64.9.12 Tmatrix3_extended.transpose . . . . . . . . . . . . . . . . . . . . . . . . 1071
64.10 Tmatrix3_single . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1071
64.10.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1071
64.10.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1072
64.10.3 Tmatrix3_single.init_zero . . . . . . . . . . . . . . . . . . . . . . . . . . 1072
64.10.4 Tmatrix3_single.init_identity . . . . . . . . . . . . . . . . . . . . . . . . 1072
64.10.5 Tmatrix3_single.init . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1072
64.10.6 Tmatrix3_single.get_column . . . . . . . . . . . . . . . . . . . . . . . . 1072
64.10.7 Tmatrix3_single.get_row . . . . . . . . . . . . . . . . . . . . . . . . . . 1073
64.10.8 Tmatrix3_single.set_column . . . . . . . . . . . . . . . . . . . . . . . . 1073
64.10.9 Tmatrix3_single.set_row . . . . . . . . . . . . . . . . . . . . . . . . . . 1073
64.10.10 Tmatrix3_single.determinant . . . . . . . . . . . . . . . . . . . . . . . . 1073
64.10.11 Tmatrix3_single.inverse . . . . . . . . . . . . . . . . . . . . . . . . . . . 1073
64.10.12 Tmatrix3_single.transpose . . . . . . . . . . . . . . . . . . . . . . . . . 1073
64.11 Tmatrix4_double . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1074
64.11.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1074
64.11.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1074
64.11.3 Tmatrix4_double.init_zero . . . . . . . . . . . . . . . . . . . . . . . . . 1074
64.11.4 Tmatrix4_double.init_identity . . . . . . . . . . . . . . . . . . . . . . . 1074
64.11.5 Tmatrix4_double.init . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1074
64.11.6 Tmatrix4_double.get_column . . . . . . . . . . . . . . . . . . . . . . . . 1075
64.11.7 Tmatrix4_double.get_row . . . . . . . . . . . . . . . . . . . . . . . . . . 1075
64.11.8 Tmatrix4_double.set_column . . . . . . . . . . . . . . . . . . . . . . . . 1075
64.11.9 Tmatrix4_double.set_row . . . . . . . . . . . . . . . . . . . . . . . . . . 1075
64.11.10 Tmatrix4_double.determinant . . . . . . . . . . . . . . . . . . . . . . . . 1075
64.11.11 Tmatrix4_double.inverse . . . . . . . . . . . . . . . . . . . . . . . . . . 1076
66
CONTENTS
64.11.12 Tmatrix4_double.transpose . . . . . . . . . . . . . . . . . . . . . . . . . 1076
64.12 Tmatrix4_extended . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1076
64.12.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1076
64.12.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1076
64.12.3 Tmatrix4_extended.init_zero . . . . . . . . . . . . . . . . . . . . . . . . 1076
64.12.4 Tmatrix4_extended.init_identity . . . . . . . . . . . . . . . . . . . . . . 1077
64.12.5 Tmatrix4_extended.init . . . . . . . . . . . . . . . . . . . . . . . . . . . 1077
64.12.6 Tmatrix4_extended.get_column . . . . . . . . . . . . . . . . . . . . . . . 1077
64.12.7 Tmatrix4_extended.get_row . . . . . . . . . . . . . . . . . . . . . . . . 1077
64.12.8 Tmatrix4_extended.set_column . . . . . . . . . . . . . . . . . . . . . . . 1077
64.12.9 Tmatrix4_extended.set_row . . . . . . . . . . . . . . . . . . . . . . . . . 1078
64.12.10 Tmatrix4_extended.determinant . . . . . . . . . . . . . . . . . . . . . . 1078
64.12.11 Tmatrix4_extended.inverse . . . . . . . . . . . . . . . . . . . . . . . . . 1078
64.12.12 Tmatrix4_extended.transpose . . . . . . . . . . . . . . . . . . . . . . . . 1078
64.13 Tmatrix4_single . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1078
64.13.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1078
64.13.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1079
64.13.3 Tmatrix4_single.init_zero . . . . . . . . . . . . . . . . . . . . . . . . . . 1079
64.13.4 Tmatrix4_single.init_identity . . . . . . . . . . . . . . . . . . . . . . . . 1079
64.13.5 Tmatrix4_single.init . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1079
64.13.6 Tmatrix4_single.get_column . . . . . . . . . . . . . . . . . . . . . . . . 1079
64.13.7 Tmatrix4_single.get_row . . . . . . . . . . . . . . . . . . . . . . . . . . 1080
64.13.8 Tmatrix4_single.set_column . . . . . . . . . . . . . . . . . . . . . . . . 1080
64.13.9 Tmatrix4_single.set_row . . . . . . . . . . . . . . . . . . . . . . . . . . 1080
64.13.10 Tmatrix4_single.determinant . . . . . . . . . . . . . . . . . . . . . . . . 1080
64.13.11 Tmatrix4_single.inverse . . . . . . . . . . . . . . . . . . . . . . . . . . . 1080
64.13.12 Tmatrix4_single.transpose . . . . . . . . . . . . . . . . . . . . . . . . . 1081
64.14 Tvector2_double . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1081
64.14.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1081
64.14.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1081
64.14.3 Tvector2_double.init_zero . . . . . . . . . . . . . . . . . . . . . . . . . 1081
64.14.4 Tvector2_double.init_one . . . . . . . . . . . . . . . . . . . . . . . . . . 1081
64.14.5 Tvector2_double.init . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1081
64.14.6 Tvector2_double.length . . . . . . . . . . . . . . . . . . . . . . . . . . . 1082
64.14.7 Tvector2_double.squared_length . . . . . . . . . . . . . . . . . . . . . . 1082
64.15 Tvector2_extended . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1082
64.15.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1082
64.15.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1082
64.15.3 Tvector2_extended.init_zero . . . . . . . . . . . . . . . . . . . . . . . . 1082
64.15.4 Tvector2_extended.init_one . . . . . . . . . . . . . . . . . . . . . . . . . 1082
67
CONTENTS
64.15.5 Tvector2_extended.init . . . . . . . . . . . . . . . . . . . . . . . . . . . 1083
64.15.6 Tvector2_extended.length . . . . . . . . . . . . . . . . . . . . . . . . . . 1083
64.15.7 Tvector2_extended.squared_length . . . . . . . . . . . . . . . . . . . . . 1083
64.16 Tvector2_single . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1083
64.16.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1083
64.16.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1083
64.16.3 Tvector2_single.init_zero . . . . . . . . . . . . . . . . . . . . . . . . . . 1083
64.16.4 Tvector2_single.init_one . . . . . . . . . . . . . . . . . . . . . . . . . . 1084
64.16.5 Tvector2_single.init . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1084
64.16.6 Tvector2_single.length . . . . . . . . . . . . . . . . . . . . . . . . . . . 1084
64.16.7 Tvector2_single.squared_length . . . . . . . . . . . . . . . . . . . . . . 1084
64.17 Tvector3_double . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1084
64.17.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1084
64.17.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1084
64.17.3 Tvector3_double.init_zero . . . . . . . . . . . . . . . . . . . . . . . . . 1085
64.17.4 Tvector3_double.init_one . . . . . . . . . . . . . . . . . . . . . . . . . . 1085
64.17.5 Tvector3_double.init . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1085
64.17.6 Tvector3_double.length . . . . . . . . . . . . . . . . . . . . . . . . . . . 1085
64.17.7 Tvector3_double.squared_length . . . . . . . . . . . . . . . . . . . . . . 1085
64.18 Tvector3_extended . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1085
64.18.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1085
64.18.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1086
64.18.3 Tvector3_extended.init_zero . . . . . . . . . . . . . . . . . . . . . . . . 1086
64.18.4 Tvector3_extended.init_one . . . . . . . . . . . . . . . . . . . . . . . . . 1086
64.18.5 Tvector3_extended.init . . . . . . . . . . . . . . . . . . . . . . . . . . . 1086
64.18.6 Tvector3_extended.length . . . . . . . . . . . . . . . . . . . . . . . . . . 1086
64.18.7 Tvector3_extended.squared_length . . . . . . . . . . . . . . . . . . . . . 1086
64.19 Tvector3_single . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1087
64.19.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1087
64.19.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1087
64.19.3 Tvector3_single.init_zero . . . . . . . . . . . . . . . . . . . . . . . . . . 1087
64.19.4 Tvector3_single.init_one . . . . . . . . . . . . . . . . . . . . . . . . . . 1087
64.19.5 Tvector3_single.init . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1087
64.19.6 Tvector3_single.length . . . . . . . . . . . . . . . . . . . . . . . . . . . 1087
64.19.7 Tvector3_single.squared_length . . . . . . . . . . . . . . . . . . . . . . 1088
64.20 Tvector4_double . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1088
64.20.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1088
64.20.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1088
64.20.3 Tvector4_double.init_zero . . . . . . . . . . . . . . . . . . . . . . . . . 1088
64.20.4 Tvector4_double.init_one . . . . . . . . . . . . . . . . . . . . . . . . . . 1088
68
CONTENTS
64.20.5 Tvector4_double.init . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1088
64.20.6 Tvector4_double.length . . . . . . . . . . . . . . . . . . . . . . . . . . . 1089
64.20.7 Tvector4_double.squared_length . . . . . . . . . . . . . . . . . . . . . . 1089
64.21 Tvector4_extended . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1089
64.21.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1089
64.21.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1089
64.21.3 Tvector4_extended.init_zero . . . . . . . . . . . . . . . . . . . . . . . . 1089
64.21.4 Tvector4_extended.init_one . . . . . . . . . . . . . . . . . . . . . . . . . 1089
64.21.5 Tvector4_extended.init . . . . . . . . . . . . . . . . . . . . . . . . . . . 1090
64.21.6 Tvector4_extended.length . . . . . . . . . . . . . . . . . . . . . . . . . . 1090
64.21.7 Tvector4_extended.squared_length . . . . . . . . . . . . . . . . . . . . . 1090
64.22 Tvector4_single . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1090
64.22.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1090
64.22.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1090
64.22.3 Tvector4_single.init_zero . . . . . . . . . . . . . . . . . . . . . . . . . . 1090
64.22.4 Tvector4_single.init_one . . . . . . . . . . . . . . . . . . . . . . . . . . 1091
64.22.5 Tvector4_single.init . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1091
64.22.6 Tvector4_single.length . . . . . . . . . . . . . . . . . . . . . . . . . . . 1091
64.22.7 Tvector4_single.squared_length . . . . . . . . . . . . . . . . . . . . . . 1091
65 Reference for unit ’mmx’ 1092
65.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1092
65.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1092
65.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1092
65.3.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1092
65.3.2 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1093
65.4 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1094
65.4.1 emms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1094
65.4.2 femms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1095
66 Reference for unit ’Mouse’ 1096
66.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1096
66.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1096
66.3 Writing a custom mouse driver . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1096
66.4 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1098
66.4.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1098
66.4.2 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1100
66.4.3 Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1100
66.5 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1101
66.5.1 DetectMouse . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1101
66.5.2 DoneMouse . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1101
69
CONTENTS
66.5.3 GetMouseButtons . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1102
66.5.4 GetMouseDriver . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1102
66.5.5 GetMouseEvent . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1103
66.5.6 GetMouseX . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1103
66.5.7 GetMouseY . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1104
66.5.8 HideMouse . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1104
66.5.9 InitMouse . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1105
66.5.10 PollMouseEvent . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1105
66.5.11 PutMouseEvent . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1106
66.5.12 SetMouseDriver . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1106
66.5.13 SetMouseXY . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1106
66.5.14 ShowMouse . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1107
67 Reference for unit ’Objects’ 1108
67.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1108
67.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1108
67.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1108
67.3.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1108
67.3.2 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1111
67.3.3 Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1114
67.4 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1114
67.4.1 Abstract . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1114
67.4.2 CallPointerConstructor . . . . . . . . . . . . . . . . . . . . . . . . . . . 1115
67.4.3 CallPointerLocal . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1115
67.4.4 CallPointerMethod . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1115
67.4.5 CallPointerMethodLocal . . . . . . . . . . . . . . . . . . . . . . . . . . 1116
67.4.6 CallVoidConstructor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1116
67.4.7 CallVoidLocal . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1116
67.4.8 CallVoidMethod . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1117
67.4.9 CallVoidMethodLocal . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1117
67.4.10 DisposeStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1117
67.4.11 LongDiv . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1117
67.4.12 LongMul . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1118
67.4.13 NewStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1118
67.4.14 RegisterObjects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1118
67.4.15 RegisterType . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1119
67.4.16 SetStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1120
67.5 TBufStream . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1121
67.5.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1121
67.5.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1121
70
CONTENTS
67.5.3 TBufStream.Init . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1121
67.5.4 TBufStream.Done . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1122
67.5.5 TBufStream.Close . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1122
67.5.6 TBufStream.Flush . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1122
67.5.7 TBufStream.Truncate . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1123
67.5.8 TBufStream.Seek . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1123
67.5.9 TBufStream.Open . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1124
67.5.10 TBufStream.Read . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1124
67.5.11 TBufStream.Write . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1124
67.6 TCollection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1125
67.6.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1125
67.6.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1125
67.6.3 TCollection.Init . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1125
67.6.4 TCollection.Load . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1126
67.6.5 TCollection.Done . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1127
67.6.6 TCollection.At . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1127
67.6.7 TCollection.IndexOf . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1128
67.6.8 TCollection.GetItem . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1128
67.6.9 TCollection.LastThat . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1129
67.6.10 TCollection.FirstThat . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1130
67.6.11 TCollection.Pack . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1130
67.6.12 TCollection.FreeAll . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1131
67.6.13 TCollection.DeleteAll . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1132
67.6.14 TCollection.Free . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1133
67.6.15 TCollection.Insert . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1134
67.6.16 TCollection.Delete . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1134
67.6.17 TCollection.AtFree . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1135
67.6.18 TCollection.FreeItem . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1135
67.6.19 TCollection.AtDelete . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1136
67.6.20 TCollection.ForEach . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1136
67.6.21 TCollection.SetLimit . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1137
67.6.22 TCollection.Error . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1137
67.6.23 TCollection.AtPut . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1138
67.6.24 TCollection.AtInsert . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1138
67.6.25 TCollection.Store . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1139
67.6.26 TCollection.PutItem . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1139
67.7 TDosStream . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1139
67.7.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1139
67.7.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1140
67.7.3 TDosStream.Init . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1140
71
CONTENTS
67.7.4 TDosStream.Done . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1140
67.7.5 TDosStream.Close . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1141
67.7.6 TDosStream.Truncate . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1141
67.7.7 TDosStream.Seek . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1142
67.7.8 TDosStream.Open . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1143
67.7.9 TDosStream.Read . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1143
67.7.10 TDosStream.Write . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1144
67.8 TMemoryStream . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1144
67.8.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1144
67.8.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1144
67.8.3 TMemoryStream.Init . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1144
67.8.4 TMemoryStream.Done . . . . . . . . . . . . . . . . . . . . . . . . . . . 1145
67.8.5 TMemoryStream.Truncate . . . . . . . . . . . . . . . . . . . . . . . . . 1145
67.8.6 TMemoryStream.Read . . . . . . . . . . . . . . . . . . . . . . . . . . . 1146
67.8.7 TMemoryStream.Write . . . . . . . . . . . . . . . . . . . . . . . . . . . 1146
67.9 TObject . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1146
67.9.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1146
67.9.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1146
67.9.3 TObject.Init . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1146
67.9.4 TObject.Free . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1147
67.9.5 TObject.Is_Object . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1147
67.9.6 TObject.Done . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1148
67.10 TPoint . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1148
67.10.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1148
67.11 TRect . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1148
67.11.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1148
67.11.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1148
67.11.3 TRect.Empty . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1149
67.11.4 TRect.Equals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1150
67.11.5 TRect.Contains . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1150
67.11.6 TRect.Copy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1150
67.11.7 TRect.Union . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1151
67.11.8 TRect.Intersect . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1151
67.11.9 TRect.Move . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1152
67.11.10 TRect.Grow . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1153
67.11.11 TRect.Assign . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1153
67.12 TResourceCollection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1154
67.12.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1154
67.12.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1154
67.12.3 TResourceCollection.KeyOf . . . . . . . . . . . . . . . . . . . . . . . . 1154
72
CONTENTS
67.12.4 TResourceCollection.GetItem . . . . . . . . . . . . . . . . . . . . . . . . 1155
67.12.5 TResourceCollection.FreeItem . . . . . . . . . . . . . . . . . . . . . . . 1155
67.12.6 TResourceCollection.PutItem . . . . . . . . . . . . . . . . . . . . . . . . 1155
67.13 TResourceFile . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1155
67.13.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1155
67.13.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1156
67.13.3 TResourceFile.Init . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1156
67.13.4 TResourceFile.Done . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1156
67.13.5 TResourceFile.Count . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1156
67.13.6 TResourceFile.KeyAt . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1157
67.13.7 TResourceFile.Get . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1157
67.13.8 TResourceFile.SwitchTo . . . . . . . . . . . . . . . . . . . . . . . . . . 1157
67.13.9 TResourceFile.Flush . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1157
67.13.10 TResourceFile.Delete . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1158
67.13.11 TResourceFile.Put . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1158
67.14 TSortedCollection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1158
67.14.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1158
67.14.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1159
67.14.3 TSortedCollection.Init . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1159
67.14.4 TSortedCollection.Load . . . . . . . . . . . . . . . . . . . . . . . . . . . 1159
67.14.5 TSortedCollection.KeyOf . . . . . . . . . . . . . . . . . . . . . . . . . . 1159
67.14.6 TSortedCollection.IndexOf . . . . . . . . . . . . . . . . . . . . . . . . . 1160
67.14.7 TSortedCollection.Compare . . . . . . . . . . . . . . . . . . . . . . . . 1160
67.14.8 TSortedCollection.Search . . . . . . . . . . . . . . . . . . . . . . . . . . 1161
67.14.9 TSortedCollection.Insert . . . . . . . . . . . . . . . . . . . . . . . . . . 1162
67.14.10 TSortedCollection.Store . . . . . . . . . . . . . . . . . . . . . . . . . . . 1163
67.15 TStrCollection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1164
67.15.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1164
67.15.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1164
67.15.3 TStrCollection.Compare . . . . . . . . . . . . . . . . . . . . . . . . . . 1164
67.15.4 TStrCollection.GetItem . . . . . . . . . . . . . . . . . . . . . . . . . . . 1165
67.15.5 TStrCollection.FreeItem . . . . . . . . . . . . . . . . . . . . . . . . . . 1165
67.15.6 TStrCollection.PutItem . . . . . . . . . . . . . . . . . . . . . . . . . . . 1165
67.16 TStream . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1166
67.16.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1166
67.16.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1166
67.16.3 TStream.Init . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1166
67.16.4 TStream.Get . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1166
67.16.5 TStream.StrRead . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1167
67.16.6 TStream.GetPos . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1168
73
CONTENTS
67.16.7 TStream.GetSize . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1168
67.16.8 TStream.ReadStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1169
67.16.9 TStream.Open . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1170
67.16.10 TStream.Close . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1170
67.16.11 TStream.Reset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1170
67.16.12 TStream.Flush . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1171
67.16.13 TStream.Truncate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1171
67.16.14 TStream.Put . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1171
67.16.15 TStream.StrWrite . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1172
67.16.16 TStream.WriteStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1172
67.16.17 TStream.Seek . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1172
67.16.18 TStream.Error . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1172
67.16.19 TStream.Read . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1173
67.16.20 TStream.Write . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1173
67.16.21 TStream.CopyFrom . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1174
67.17 TStringCollection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1174
67.17.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1174
67.17.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1175
67.17.3 TStringCollection.GetItem . . . . . . . . . . . . . . . . . . . . . . . . . 1175
67.17.4 TStringCollection.Compare . . . . . . . . . . . . . . . . . . . . . . . . . 1175
67.17.5 TStringCollection.FreeItem . . . . . . . . . . . . . . . . . . . . . . . . . 1176
67.17.6 TStringCollection.PutItem . . . . . . . . . . . . . . . . . . . . . . . . . 1176
67.18 TStringList . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1176
67.18.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1176
67.18.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1177
67.18.3 TStringList.Load . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1177
67.18.4 TStringList.Done . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1177
67.18.5 TStringList.Get . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1177
67.19 TStrListMaker . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1178
67.19.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1178
67.19.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1178
67.19.3 TStrListMaker.Init . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1178
67.19.4 TStrListMaker.Done . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1178
67.19.5 TStrListMaker.Put . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1178
67.19.6 TStrListMaker.Store . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1179
67.20 TUnSortedStrCollection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1179
67.20.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1179
67.20.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1179
67.20.3 TUnSortedStrCollection.Insert . . . . . . . . . . . . . . . . . . . . . . . 1179
74
CONTENTS
68 Reference for unit ’objpas’ 1181
68.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1181
68.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1181
68.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1181
68.3.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1181
68.3.2 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1181
69 Reference for unit ’ports’ 1183
69.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1183
69.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1183
69.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1183
69.3.1 Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1183
69.4 tport . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1184
69.4.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1184
69.4.2 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1184
69.4.3 tport.pp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1184
69.5 tportl . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1185
69.5.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1185
69.5.2 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1185
69.5.3 tportl.pp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1185
69.6 tportw . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1185
69.6.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1185
69.6.2 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1185
69.6.3 tportw.pp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1185
70 Reference for unit ’printer’ 1186
70.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1186
70.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1186
70.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1186
70.3.1 Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1186
70.4 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1186
70.4.1 AssignLst . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1186
70.4.2 InitPrinter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1187
70.4.3 IsLstAvailable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1187
71 Reference for unit ’sharemem’ 1188
71.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1188
71.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1188
72 Reference for unit ’Sockets’ 1189
72.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1189
75
CONTENTS
72.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1189
72.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1189
72.3.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1189
72.3.2 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1210
72.4 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1214
72.4.1 Accept . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1214
72.4.2 Bind . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1216
72.4.3 CloseSocket . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1216
72.4.4 Connect . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1216
72.4.5 fpaccept . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1218
72.4.6 fpbind . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1219
72.4.7 fpconnect . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1220
72.4.8 fpgetpeername . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1222
72.4.9 fpgetsockname . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1222
72.4.10 fpgetsockopt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1223
72.4.11 fplisten . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1223
72.4.12 fprecv . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1223
72.4.13 fprecvfrom . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1224
72.4.14 fpsend . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1224
72.4.15 fpsendto . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1225
72.4.16 fpsetsockopt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1225
72.4.17 fpshutdown . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1226
72.4.18 fpsocket . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1226
72.4.19 fpsocketpair . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1227
72.4.20 HostAddrToStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1227
72.4.21 HostAddrToStr6 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1227
72.4.22 HostToNet . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1227
72.4.23 htonl . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1228
72.4.24 htons . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1228
72.4.25 NetAddrToStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1228
72.4.26 NetAddrToStr6 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1228
72.4.27 NetToHost . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1229
72.4.28 NToHl . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1229
72.4.29 NToHs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1229
72.4.30 ShortHostToNet . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1229
72.4.31 ShortNetToHost . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1230
72.4.32 Sock2File . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1230
72.4.33 Sock2Text . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1230
72.4.34 socketerror . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1230
72.4.35 Str2UnixSockAddr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1231
76
CONTENTS
72.4.36 StrToHostAddr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1231
72.4.37 StrToHostAddr6 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1231
72.4.38 StrToNetAddr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1231
72.4.39 StrToNetAddr6 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1232
73 Reference for unit ’strings’ 1233
73.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1233
73.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1233
73.3 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1233
73.3.1 stralloc . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1233
73.3.2 strcat . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1233
73.3.3 strcomp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1234
73.3.4 strcopy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1234
73.3.5 strdispose . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1235
73.3.6 strecopy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1236
73.3.7 strend . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1236
73.3.8 stricomp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1237
73.3.9 stripos . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1237
73.3.10 striscan . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1238
73.3.11 strlcat . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1238
73.3.12 strlcomp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1239
73.3.13 strlcopy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1239
73.3.14 strlen . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1240
73.3.15 strlicomp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1240
73.3.16 strlower . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1241
73.3.17 strmove . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1241
73.3.18 strnew . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1242
73.3.19 strpas . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1243
73.3.20 strpcopy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1243
73.3.21 strpos . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1244
73.3.22 strriscan . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1244
73.3.23 strrscan . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1245
73.3.24 strscan . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1245
73.3.25 strupper . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1245
74 Reference for unit ’strutils’ 1246
74.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1246
74.2 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1246
74.2.1 Resource strings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1246
74.2.2 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1246
74.2.3 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1247
77
CONTENTS
74.3 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1249
74.3.1 AddChar . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1249
74.3.2 AddCharR . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1249
74.3.3 AnsiContainsStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1249
74.3.4 AnsiContainsText . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1249
74.3.5 AnsiEndsStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1250
74.3.6 AnsiEndsText . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1250
74.3.7 AnsiIndexStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1250
74.3.8 AnsiIndexText . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1251
74.3.9 AnsiLeftStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1251
74.3.10 AnsiMatchStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1251
74.3.11 AnsiMatchText . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1251
74.3.12 AnsiMidStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1252
74.3.13 AnsiProperCase . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1252
74.3.14 AnsiReplaceStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1252
74.3.15 AnsiReplaceText . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1253
74.3.16 AnsiResemblesText . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1253
74.3.17 AnsiReverseString . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1253
74.3.18 AnsiRightStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1253
74.3.19 AnsiStartsStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1254
74.3.20 AnsiStartsText . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1254
74.3.21 BinToHex . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1254
74.3.22 Copy2Space . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1255
74.3.23 Copy2SpaceDel . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1255
74.3.24 Copy2Symb . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1255
74.3.25 Copy2SymbDel . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1256
74.3.26 Dec2Numb . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1256
74.3.27 DecodeSoundexInt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1256
74.3.28 DecodeSoundexWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1256
74.3.29 DelChars . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1257
74.3.30 DelSpace . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1257
74.3.31 DelSpace1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1257
74.3.32 DupeString . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1257
74.3.33 ExtractDelimited . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1258
74.3.34 ExtractSubstr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1258
74.3.35 ExtractWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1259
74.3.36 ExtractWordPos . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1259
74.3.37 FindMatchesBoyerMooreCaseInSensitive . . . . . . . . . . . . . . . . . 1259
74.3.38 FindMatchesBoyerMooreCaseSensitive . . . . . . . . . . . . . . . . . . 1260
74.3.39 FindPart . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1260
78
CONTENTS
74.3.40 GetCmdLineArg . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1261
74.3.41 Hex2Dec . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1261
74.3.42 HexToBin . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1261
74.3.43 IfThen . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1262
74.3.44 IndexStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1262
74.3.45 IntToBin . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1262
74.3.46 IntToRoman . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1262
74.3.47 IsEmptyStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1263
74.3.48 IsWild . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1263
74.3.49 IsWordPresent . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1263
74.3.50 LeftBStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1264
74.3.51 LeftStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1264
74.3.52 MatchStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1264
74.3.53 MidBStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1265
74.3.54 MidStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1265
74.3.55 NaturalCompareText . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1265
74.3.56 NPos . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1266
74.3.57 Numb2Dec . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1266
74.3.58 Numb2USA . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1266
74.3.59 PadCenter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1267
74.3.60 PadLeft . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1267
74.3.61 PadRight . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1267
74.3.62 PosEx . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1267
74.3.63 PosSet . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1268
74.3.64 PosSetEx . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1268
74.3.65 RandomFrom . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1268
74.3.66 Removeleadingchars . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1269
74.3.67 RemovePadChars . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1269
74.3.68 RemoveTrailingChars . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1269
74.3.69 ReplaceStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1270
74.3.70 ReplaceText . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1270
74.3.71 ReverseString . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1270
74.3.72 RightBStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1270
74.3.73 RightStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1271
74.3.74 RomanToInt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1271
74.3.75 RomanToIntDef . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1271
74.3.76 RPos . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1272
74.3.77 RPosex . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1272
74.3.78 SearchBuf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1272
74.3.79 Soundex . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1273
79
CONTENTS
74.3.80 SoundexCompare . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1273
74.3.81 SoundexInt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1273
74.3.82 SoundexProc . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1274
74.3.83 SoundexSimilar . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1274
74.3.84 SoundexWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1274
74.3.85 StringReplace . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1275
74.3.86 StringsReplace . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1275
74.3.87 StuffString . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1276
74.3.88 Tab2Space . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1276
74.3.89 TrimLeftSet . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1276
74.3.90 TrimRightSet . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1276
74.3.91 TrimSet . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1277
74.3.92 TryRomanToInt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1277
74.3.93 WordCount . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1277
74.3.94 WordPosition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1278
74.3.95 XorDecode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1278
74.3.96 XorEncode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1278
74.3.97 XorString . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1279
75 Reference for unit ’System’ 1280
75.1 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1280
75.2 Unicode and codepage support . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1280
75.3 Miscellaneous functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1281
75.4 Operating System functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1282
75.5 String handling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1282
75.6 Mathematical routines . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1283
75.7 Memory management functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1284
75.8 File handling functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1284
75.9 Run-Time Error behaviour . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1285
75.10 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1285
75.10.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1285
75.10.2 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1310
75.10.3 Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1348
75.11 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1352
75.11.1 abs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1352
75.11.2 AbstractError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1353
75.11.3 AcquireExceptionObject . . . . . . . . . . . . . . . . . . . . . . . . . . 1353
75.11.4 add(variant,variant):variant . . . . . . . . . . . . . . . . . . . . . . . . . 1353
75.11.5 AddExitProc . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1354
75.11.6 Addr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1354
80
CONTENTS
75.11.7 Align . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1355
75.11.8 AllocMem . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1355
75.11.9 AnsiToUtf8 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1355
75.11.10 Append . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1355
75.11.11 arctan . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1356
75.11.12 ArrayStringToPPchar . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1356
75.11.13 Assert . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1357
75.11.14 Assign . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1357
75.11.15 assign(ansistring):olevariant . . . . . . . . . . . . . . . . . . . . . . . . . 1358
75.11.16 assign(ansistring):variant . . . . . . . . . . . . . . . . . . . . . . . . . . 1358
75.11.17 assign(Boolean):olevariant . . . . . . . . . . . . . . . . . . . . . . . . . 1358
75.11.18 assign(Boolean):variant . . . . . . . . . . . . . . . . . . . . . . . . . . . 1359
75.11.19 assign(Byte):olevariant . . . . . . . . . . . . . . . . . . . . . . . . . . . 1359
75.11.20 assign(Byte):variant . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1359
75.11.21 assign(Char):olevariant . . . . . . . . . . . . . . . . . . . . . . . . . . . 1359
75.11.22 assign(Char):variant . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1359
75.11.23 assign(comp):olevariant . . . . . . . . . . . . . . . . . . . . . . . . . . . 1359
75.11.24 assign(comp):variant . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1360
75.11.25 assign(currency):olevariant . . . . . . . . . . . . . . . . . . . . . . . . . 1360
75.11.26 assign(currency):variant . . . . . . . . . . . . . . . . . . . . . . . . . . . 1360
75.11.27 assign(Double):olevariant . . . . . . . . . . . . . . . . . . . . . . . . . . 1360
75.11.28 assign(Double):variant . . . . . . . . . . . . . . . . . . . . . . . . . . . 1360
75.11.29 assign(DWord):olevariant . . . . . . . . . . . . . . . . . . . . . . . . . . 1360
75.11.30 assign(DWord):variant . . . . . . . . . . . . . . . . . . . . . . . . . . . 1361
75.11.31 assign(extended):olevariant . . . . . . . . . . . . . . . . . . . . . . . . . 1361
75.11.32 assign(extended):variant . . . . . . . . . . . . . . . . . . . . . . . . . . . 1361
75.11.33 assign(Int64):olevariant . . . . . . . . . . . . . . . . . . . . . . . . . . . 1361
75.11.34 assign(Int64):variant . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1361
75.11.35 assign(longbool):olevariant . . . . . . . . . . . . . . . . . . . . . . . . . 1361
75.11.36 assign(longbool):variant . . . . . . . . . . . . . . . . . . . . . . . . . . . 1362
75.11.37 assign(LongInt):olevariant . . . . . . . . . . . . . . . . . . . . . . . . . 1362
75.11.38 assign(LongInt):variant . . . . . . . . . . . . . . . . . . . . . . . . . . . 1362
75.11.39 assign(olevariant):ansistring . . . . . . . . . . . . . . . . . . . . . . . . . 1362
75.11.40 assign(olevariant):Boolean . . . . . . . . . . . . . . . . . . . . . . . . . 1362
75.11.41 assign(olevariant):Byte . . . . . . . . . . . . . . . . . . . . . . . . . . . 1362
75.11.42 assign(olevariant):Char . . . . . . . . . . . . . . . . . . . . . . . . . . . 1363
75.11.43 assign(olevariant):comp . . . . . . . . . . . . . . . . . . . . . . . . . . . 1363
75.11.44 assign(olevariant):currency . . . . . . . . . . . . . . . . . . . . . . . . . 1363
75.11.45 assign(olevariant):Double . . . . . . . . . . . . . . . . . . . . . . . . . . 1363
75.11.46 assign(olevariant):DWord . . . . . . . . . . . . . . . . . . . . . . . . . . 1363
81
CONTENTS
75.11.47 assign(olevariant):extended . . . . . . . . . . . . . . . . . . . . . . . . . 1363
75.11.48 assign(olevariant):Int64 . . . . . . . . . . . . . . . . . . . . . . . . . . . 1364
75.11.49 assign(olevariant):longbool . . . . . . . . . . . . . . . . . . . . . . . . . 1364
75.11.50 assign(olevariant):LongInt . . . . . . . . . . . . . . . . . . . . . . . . . 1364
75.11.51 assign(olevariant):QWord . . . . . . . . . . . . . . . . . . . . . . . . . . 1364
75.11.52 assign(olevariant):Real . . . . . . . . . . . . . . . . . . . . . . . . . . . 1364
75.11.53 assign(olevariant):ShortInt . . . . . . . . . . . . . . . . . . . . . . . . . 1364
75.11.54 assign(olevariant):shortstring . . . . . . . . . . . . . . . . . . . . . . . . 1365
75.11.55 assign(olevariant):single . . . . . . . . . . . . . . . . . . . . . . . . . . . 1365
75.11.56 assign(olevariant):SmallInt . . . . . . . . . . . . . . . . . . . . . . . . . 1365
75.11.57 assign(olevariant):TDateTime . . . . . . . . . . . . . . . . . . . . . . . . 1365
75.11.58 assign(olevariant):TError . . . . . . . . . . . . . . . . . . . . . . . . . . 1365
75.11.59 assign(olevariant):UnicodeString . . . . . . . . . . . . . . . . . . . . . . 1365
75.11.60 assign(olevariant):variant . . . . . . . . . . . . . . . . . . . . . . . . . . 1366
75.11.61 assign(olevariant):WideChar . . . . . . . . . . . . . . . . . . . . . . . . 1366
75.11.62 assign(olevariant):widestring . . . . . . . . . . . . . . . . . . . . . . . . 1366
75.11.63 assign(olevariant):Word . . . . . . . . . . . . . . . . . . . . . . . . . . . 1366
75.11.64 assign(olevariant):wordbool . . . . . . . . . . . . . . . . . . . . . . . . . 1366
75.11.65 assign(QWord):olevariant . . . . . . . . . . . . . . . . . . . . . . . . . . 1366
75.11.66 assign(QWord):variant . . . . . . . . . . . . . . . . . . . . . . . . . . . 1367
75.11.67 assign(Real):olevariant . . . . . . . . . . . . . . . . . . . . . . . . . . . 1367
75.11.68 assign(Real):variant . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1367
75.11.69 assign(real48):Double . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1367
75.11.70 assign(real48):extended . . . . . . . . . . . . . . . . . . . . . . . . . . . 1367
75.11.71 assign(ShortInt):olevariant . . . . . . . . . . . . . . . . . . . . . . . . . 1367
75.11.72 assign(ShortInt):variant . . . . . . . . . . . . . . . . . . . . . . . . . . . 1368
75.11.73 assign(shortstring):olevariant . . . . . . . . . . . . . . . . . . . . . . . . 1368
75.11.74 assign(shortstring):variant . . . . . . . . . . . . . . . . . . . . . . . . . . 1368
75.11.75 assign(single):olevariant . . . . . . . . . . . . . . . . . . . . . . . . . . . 1368
75.11.76 assign(single):variant . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1368
75.11.77 assign(SmallInt):olevariant . . . . . . . . . . . . . . . . . . . . . . . . . 1368
75.11.78 assign(SmallInt):variant . . . . . . . . . . . . . . . . . . . . . . . . . . . 1369
75.11.79 assign(TDateTime):olevariant . . . . . . . . . . . . . . . . . . . . . . . . 1369
75.11.80 assign(TDateTime):variant . . . . . . . . . . . . . . . . . . . . . . . . . 1369
75.11.81 assign(TError):olevariant . . . . . . . . . . . . . . . . . . . . . . . . . . 1369
75.11.82 assign(TError):variant . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1369
75.11.83 assign(UCS4String):variant . . . . . . . . . . . . . . . . . . . . . . . . . 1369
75.11.84 assign(UnicodeString):olevariant . . . . . . . . . . . . . . . . . . . . . . 1370
75.11.85 assign(UnicodeString):variant . . . . . . . . . . . . . . . . . . . . . . . . 1370
75.11.86 assign(UTF8String):variant . . . . . . . . . . . . . . . . . . . . . . . . . 1370
82
CONTENTS
75.11.87 assign(variant):ansistring . . . . . . . . . . . . . . . . . . . . . . . . . . 1370
75.11.88 assign(variant):Boolean . . . . . . . . . . . . . . . . . . . . . . . . . . . 1370
75.11.89 assign(variant):Byte . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1370
75.11.90 assign(variant):Char . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1371
75.11.91 assign(variant):comp . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1371
75.11.92 assign(variant):currency . . . . . . . . . . . . . . . . . . . . . . . . . . . 1371
75.11.93 assign(variant):Double . . . . . . . . . . . . . . . . . . . . . . . . . . . 1371
75.11.94 assign(variant):DWord . . . . . . . . . . . . . . . . . . . . . . . . . . . 1371
75.11.95 assign(variant):extended . . . . . . . . . . . . . . . . . . . . . . . . . . . 1371
75.11.96 assign(variant):Int64 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1372
75.11.97 assign(variant):longbool . . . . . . . . . . . . . . . . . . . . . . . . . . . 1372
75.11.98 assign(variant):LongInt . . . . . . . . . . . . . . . . . . . . . . . . . . . 1372
75.11.99 assign(variant):olevariant . . . . . . . . . . . . . . . . . . . . . . . . . . 1372
75.11.100assign(variant):QWord . . . . . . . . . . . . . . . . . . . . . . . . . . . 1372
75.11.101assign(variant):Real . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1372
75.11.102assign(variant):ShortInt . . . . . . . . . . . . . . . . . . . . . . . . . . . 1373
75.11.103assign(variant):shortstring . . . . . . . . . . . . . . . . . . . . . . . . . . 1373
75.11.104assign(variant):single . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1373
75.11.105assign(variant):SmallInt . . . . . . . . . . . . . . . . . . . . . . . . . . . 1373
75.11.106assign(variant):TDateTime . . . . . . . . . . . . . . . . . . . . . . . . . 1373
75.11.107assign(variant):TError . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1373
75.11.108assign(variant):unicodestring . . . . . . . . . . . . . . . . . . . . . . . . 1374
75.11.109assign(variant):UTF8String . . . . . . . . . . . . . . . . . . . . . . . . . 1374
75.11.110assign(variant):WideChar . . . . . . . . . . . . . . . . . . . . . . . . . . 1374
75.11.111assign(variant):widestring . . . . . . . . . . . . . . . . . . . . . . . . . . 1374
75.11.112assign(variant):Word . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1374
75.11.113assign(variant):wordbool . . . . . . . . . . . . . . . . . . . . . . . . . . 1374
75.11.114assign(WideChar):olevariant . . . . . . . . . . . . . . . . . . . . . . . . 1375
75.11.115assign(WideChar):variant . . . . . . . . . . . . . . . . . . . . . . . . . . 1375
75.11.116assign(widestring):olevariant . . . . . . . . . . . . . . . . . . . . . . . . 1375
75.11.117assign(widestring):variant . . . . . . . . . . . . . . . . . . . . . . . . . . 1375
75.11.118assign(Word):olevariant . . . . . . . . . . . . . . . . . . . . . . . . . . . 1375
75.11.119assign(Word):variant . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1375
75.11.120assign(wordbool):olevariant . . . . . . . . . . . . . . . . . . . . . . . . . 1376
75.11.121assign(wordbool):variant . . . . . . . . . . . . . . . . . . . . . . . . . . 1376
75.11.122Assigned . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1376
75.11.123BasicEventCreate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1377
75.11.124basiceventdestroy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1377
75.11.125basiceventResetEvent . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1377
75.11.126basiceventSetEvent . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1377
83
CONTENTS
75.11.127basiceventWaitFor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1377
75.11.128BeginThread . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1378
75.11.129BEtoN . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1378
75.11.130binStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1378
75.11.131BlockRead . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1379
75.11.132BlockWrite . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1380
75.11.133Break . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1380
75.11.134BsfByte . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1381
75.11.135BsfDWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1382
75.11.136BsfQWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1382
75.11.137BsfWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1382
75.11.138BsrByte . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1382
75.11.139BsrDWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1383
75.11.140BsrQWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1383
75.11.141BsrWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1383
75.11.142CaptureBacktrace . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1383
75.11.143chdir . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1384
75.11.144chr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1384
75.11.145Close . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1385
75.11.146CloseThread . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1385
75.11.147CompareByte . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1385
75.11.148CompareChar . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1386
75.11.149CompareChar0 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1388
75.11.150CompareDWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1388
75.11.151CompareWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1389
75.11.152Concat . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1390
75.11.153Continue . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1391
75.11.154Copy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1392
75.11.155CopyArray . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1392
75.11.156cos . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1393
75.11.157Cseg . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1393
75.11.158Dec . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1394
75.11.159Default . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1395
75.11.160DefaultAnsi2UnicodeMove . . . . . . . . . . . . . . . . . . . . . . . . . 1395
75.11.161DefaultAnsi2WideMove . . . . . . . . . . . . . . . . . . . . . . . . . . 1395
75.11.162DefaultUnicode2AnsiMove . . . . . . . . . . . . . . . . . . . . . . . . . 1395
75.11.163Delete . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1396
75.11.164Dispose . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1396
75.11.165divide(variant,variant):variant . . . . . . . . . . . . . . . . . . . . . . . . 1397
75.11.166DoneCriticalsection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1397
84
CONTENTS
75.11.167DoneThread . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1398
75.11.168Dseg . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1398
75.11.169DumpExceptionBackTrace . . . . . . . . . . . . . . . . . . . . . . . . . 1398
75.11.170Dump_Stack . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1399
75.11.171DynArrayBounds . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1399
75.11.172DynArrayClear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1399
75.11.173DynArrayDim . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1400
75.11.174DynArrayIndex . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1400
75.11.175DynArraySetLength . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1400
75.11.176DynArraySize . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1401
75.11.177EmptyMethod . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1401
75.11.178EndThread . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1401
75.11.179EnterCriticalsection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1401
75.11.180EnumResourceLanguages . . . . . . . . . . . . . . . . . . . . . . . . . . 1402
75.11.181EnumResourceNames . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1402
75.11.182EnumResourceTypes . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1403
75.11.183EOF . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1403
75.11.184EOLn . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1404
75.11.185equal(variant,variant):Boolean . . . . . . . . . . . . . . . . . . . . . . . 1404
75.11.186Erase . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1405
75.11.187Error . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1405
75.11.188Exclude . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1405
75.11.189Exit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1407
75.11.190exp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1408
75.11.191Fail . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1408
75.11.192FilePos . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1409
75.11.193FileSize . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1410
75.11.194FillByte . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1410
75.11.195FillChar . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1411
75.11.196FillDWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1412
75.11.197FillQWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1412
75.11.198FillWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1413
75.11.199Finalize . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1413
75.11.200FinalizeArray . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1413
75.11.201FindResource . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1414
75.11.202FindResourceEx . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1414
75.11.203float_raise . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1415
75.11.204Flush . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1415
75.11.205FlushThread . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1416
75.11.206FMADouble . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1416
85
CONTENTS
75.11.207FMAExtended . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1416
75.11.208FMASingle . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1416
75.11.209fpc_SarInt64 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1416
75.11.210FPower10 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1416
75.11.211frac . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1417
75.11.212Freemem . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1417
75.11.213Freememory . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1418
75.11.214FreeResource . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1418
75.11.215GetCPUCount . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1418
75.11.216GetCurrentThreadId . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1418
75.11.217getdir . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1419
75.11.218GetFPCHeapStatus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1419
75.11.219GetHeapStatus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1419
75.11.220GetMem . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1419
75.11.221GetMemory . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1420
75.11.222GetMemoryManager . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1420
75.11.223GetProcessID . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1420
75.11.224GetResourceManager . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1421
75.11.225GetTextCodePage . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1421
75.11.226GetThreadID . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1421
75.11.227GetThreadManager . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1421
75.11.228GetUnicodeStringManager . . . . . . . . . . . . . . . . . . . . . . . . . 1422
75.11.229GetVariantManager . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1422
75.11.230GetWideStringManager . . . . . . . . . . . . . . . . . . . . . . . . . . . 1422
75.11.231get_caller_addr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1423
75.11.232get_caller_frame . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1423
75.11.233get_caller_stackinfo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1423
75.11.234get_cmdline . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1423
75.11.235get_frame . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1424
75.11.236Get_pc_addr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1424
75.11.237greaterthan(variant,variant):Boolean . . . . . . . . . . . . . . . . . . . . 1424
75.11.238greaterthanorequal(variant,variant):Boolean . . . . . . . . . . . . . . . . 1424
75.11.239halt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1425
75.11.240hexStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1425
75.11.241hi . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1426
75.11.242High . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1426
75.11.243HINSTANCE . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1428
75.11.244Inc . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1428
75.11.245Include . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1428
75.11.246IndexByte . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1429
86
CONTENTS
75.11.247IndexChar . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1430
75.11.248IndexChar0 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1430
75.11.249IndexDWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1431
75.11.250IndexQWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1431
75.11.251Indexword . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1432
75.11.252InitCriticalSection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1432
75.11.253Initialize . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1433
75.11.254InitializeArray . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1435
75.11.255InitThread . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1435
75.11.256InitThreadVars . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1435
75.11.257Insert . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1435
75.11.258int . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1436
75.11.259intdivide(variant,variant):variant . . . . . . . . . . . . . . . . . . . . . . 1436
75.11.260InterlockedCompareExchange . . . . . . . . . . . . . . . . . . . . . . . 1437
75.11.261InterLockedDecrement . . . . . . . . . . . . . . . . . . . . . . . . . . . 1437
75.11.262InterLockedExchange . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1437
75.11.263InterLockedExchangeAdd . . . . . . . . . . . . . . . . . . . . . . . . . . 1438
75.11.264InterLockedIncrement . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1438
75.11.265IOResult . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1439
75.11.266IsDynArrayRectangular . . . . . . . . . . . . . . . . . . . . . . . . . . . 1440
75.11.267IsMemoryManagerSet . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1440
75.11.268Is_IntResource . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1440
75.11.269KillThread . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1441
75.11.270LeaveCriticalsection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1441
75.11.271leftshift(variant,variant):variant . . . . . . . . . . . . . . . . . . . . . . . 1441
75.11.272Length . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1442
75.11.273lessthan(variant,variant):Boolean . . . . . . . . . . . . . . . . . . . . . . 1442
75.11.274lessthanorequal(variant,variant):Boolean . . . . . . . . . . . . . . . . . . 1443
75.11.275LEtoN . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1443
75.11.276ln . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1443
75.11.277lo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1444
75.11.278LoadResource . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1444
75.11.279LockResource . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1445
75.11.280logicaland(variant,variant):variant . . . . . . . . . . . . . . . . . . . . . 1445
75.11.281logicalnot(variant):variant . . . . . . . . . . . . . . . . . . . . . . . . . . 1445
75.11.282logicalor(variant,variant):variant . . . . . . . . . . . . . . . . . . . . . . 1446
75.11.283logicalxor(variant,variant):variant . . . . . . . . . . . . . . . . . . . . . . 1446
75.11.284longjmp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1446
75.11.285Low . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1447
75.11.286lowerCase . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1447
87
CONTENTS
75.11.287MakeLangID . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1448
75.11.288MemSize . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1448
75.11.289mkdir . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1448
75.11.290modulus(variant,variant):variant . . . . . . . . . . . . . . . . . . . . . . 1448
75.11.291Move . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1449
75.11.292MoveChar0 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1449
75.11.293multiply(variant,variant):variant . . . . . . . . . . . . . . . . . . . . . . 1450
75.11.294negative(variant):variant . . . . . . . . . . . . . . . . . . . . . . . . . . . 1450
75.11.295New . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1450
75.11.296NtoBE . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1451
75.11.297NtoLE . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1451
75.11.298Null . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1451
75.11.299OctStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1452
75.11.300odd . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1452
75.11.301Ofs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1453
75.11.302Ord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1453
75.11.303Pack . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1454
75.11.304ParamCount . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1454
75.11.305ParamStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1455
75.11.306pi . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1455
75.11.307PopCnt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1456
75.11.308Pos . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1456
75.11.309power(variant,variant):variant . . . . . . . . . . . . . . . . . . . . . . . . 1457
75.11.310Pred . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1457
75.11.311prefetch . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1458
75.11.312ptr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1458
75.11.313RaiseList . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1459
75.11.314Random . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1459
75.11.315Randomize . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1460
75.11.316Read . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1460
75.11.317ReadBarrier . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1461
75.11.318ReadDependencyBarrier . . . . . . . . . . . . . . . . . . . . . . . . . . 1461
75.11.319ReadLn . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1461
75.11.320ReadStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1462
75.11.321ReadWriteBarrier . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1462
75.11.322Real2Double . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1462
75.11.323ReAllocMem . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1463
75.11.324ReAllocMemory . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1463
75.11.325ReleaseExceptionObject . . . . . . . . . . . . . . . . . . . . . . . . . . 1464
75.11.326Rename . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1464
88
CONTENTS
75.11.327Reset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1465
75.11.328ResumeThread . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1465
75.11.329Rewrite . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1466
75.11.330rightshift(variant,variant):variant . . . . . . . . . . . . . . . . . . . . . . 1466
75.11.331rmdir . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1467
75.11.332RolByte . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1467
75.11.333RolDWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1468
75.11.334RolQWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1468
75.11.335RolWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1468
75.11.336RorByte . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1468
75.11.337RorDWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1469
75.11.338RorQWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1469
75.11.339RorWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1469
75.11.340round . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1470
75.11.341RTLEventCreate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1470
75.11.342RTLeventdestroy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1470
75.11.343RTLeventResetEvent . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1471
75.11.344RTLeventSetEvent . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1471
75.11.345RTLeventWaitFor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1471
75.11.346RunError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1471
75.11.347SarInt64 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1472
75.11.348SarLongint . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1472
75.11.349SarShortint . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1472
75.11.350SarSmallint . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1473
75.11.351Seek . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1473
75.11.352SeekEOF . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1474
75.11.353SeekEOLn . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1474
75.11.354Seg . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1475
75.11.355SemaphoreDestroy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1475
75.11.356SemaphoreInit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1476
75.11.357SemaphorePost . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1476
75.11.358SemaphoreWait . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1476
75.11.359SetCodePage . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1477
75.11.360Setjmp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1477
75.11.361SetLength . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1478
75.11.362SetMemoryManager . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1478
75.11.363SetMultiByteConversionCodePage . . . . . . . . . . . . . . . . . . . . . 1479
75.11.364SetMultiByteFileSystemCodePage . . . . . . . . . . . . . . . . . . . . . 1479
75.11.365SetMultiByteRTLFileSystemCodePage . . . . . . . . . . . . . . . . . . . 1479
75.11.366SetResourceManager . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1480
89
CONTENTS
75.11.367SetString . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1480
75.11.368SetTextBuf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1480
75.11.369SetTextCodePage . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1481
75.11.370SetTextLineEnding . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1482
75.11.371SetThreadManager . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1482
75.11.372SetUnicodeStringManager . . . . . . . . . . . . . . . . . . . . . . . . . 1482
75.11.373SetVariantManager . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1483
75.11.374SetWideStringManager . . . . . . . . . . . . . . . . . . . . . . . . . . . 1483
75.11.375ShortCompareText . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1483
75.11.376sin . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1484
75.11.377SizeOf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1484
75.11.378SizeofResource . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1485
75.11.379Slice . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1485
75.11.380Space . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1485
75.11.381Sptr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1486
75.11.382sqr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1486
75.11.383sqrt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1487
75.11.384Sseg . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1487
75.11.385StackTop . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1487
75.11.386Str . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1488
75.11.387StringCodePage . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1489
75.11.388StringElementSize . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1490
75.11.389StringOfChar . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1490
75.11.390StringRefCount . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1490
75.11.391StringToPPChar . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1491
75.11.392StringToUnicodeChar . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1491
75.11.393StringToWideChar . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1491
75.11.394strlen . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1492
75.11.395strpas . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1492
75.11.396subtract(variant,variant):variant . . . . . . . . . . . . . . . . . . . . . . . 1492
75.11.397Succ . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1492
75.11.398SuspendThread . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1493
75.11.399Swap . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1493
75.11.400SwapEndian . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1494
75.11.401SysAllocMem . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1494
75.11.402SysAssert . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1494
75.11.403SysBackTraceStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1495
75.11.404SysFlushStdIO . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1495
75.11.405SysFreemem . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1495
75.11.406SysFreememSize . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1495
90
CONTENTS
75.11.407SysGetFPCHeapStatus . . . . . . . . . . . . . . . . . . . . . . . . . . . 1495
75.11.408SysGetHeapStatus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1496
75.11.409SysGetmem . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1496
75.11.410SysInitExceptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1496
75.11.411SysInitFPU . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1496
75.11.412SysInitStdIO . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1497
75.11.413SysMemSize . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1497
75.11.414SysReAllocMem . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1497
75.11.415SysResetFPU . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1497
75.11.416SysSetCtrlBreakHandler . . . . . . . . . . . . . . . . . . . . . . . . . . 1497
75.11.417SysTryResizeMem . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1498
75.11.418ThreadGetPriority . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1498
75.11.419ThreadSetPriority . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1498
75.11.420ThreadSwitch . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1498
75.11.421ToSingleByteFileSystemEncodedFileName . . . . . . . . . . . . . . . . 1499
75.11.422trunc . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1499
75.11.423Truncate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1499
75.11.424TryEnterCriticalsection . . . . . . . . . . . . . . . . . . . . . . . . . . . 1500
75.11.425TypeInfo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1500
75.11.426TypeOf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1501
75.11.427UCS4StringToUnicodeString . . . . . . . . . . . . . . . . . . . . . . . . 1501
75.11.428UCS4StringToWideString . . . . . . . . . . . . . . . . . . . . . . . . . . 1501
75.11.429Unassigned . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1501
75.11.430UnicodeCharLenToString . . . . . . . . . . . . . . . . . . . . . . . . . . 1501
75.11.431UnicodeCharLenToStrVar . . . . . . . . . . . . . . . . . . . . . . . . . . 1502
75.11.432UnicodeCharToString . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1502
75.11.433UnicodeCharToStrVar . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1502
75.11.434UnicodeStringToUCS4String . . . . . . . . . . . . . . . . . . . . . . . . 1503
75.11.435UnicodeToUtf8 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1503
75.11.436UniqueString . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1503
75.11.437UnlockResource . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1503
75.11.438UnPack . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1504
75.11.439upCase . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1504
75.11.440Utf8CodePointLen . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1505
75.11.441UTF8Decode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1505
75.11.442UTF8Encode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1505
75.11.443Utf8ToAnsi . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1506
75.11.444Utf8ToUnicode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1506
75.11.445Val . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1506
75.11.446VarArrayGet . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1507
91
CONTENTS
75.11.447VarArrayPut . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1507
75.11.448VarArrayRedim . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1508
75.11.449VarCast . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1508
75.11.450WaitForThreadTerminate . . . . . . . . . . . . . . . . . . . . . . . . . . 1508
75.11.451WideCharLenToString . . . . . . . . . . . . . . . . . . . . . . . . . . . 1509
75.11.452WideCharLenToStrVar . . . . . . . . . . . . . . . . . . . . . . . . . . . 1509
75.11.453WideCharToString . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1509
75.11.454WideCharToStrVar . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1510
75.11.455WideStringToUCS4String . . . . . . . . . . . . . . . . . . . . . . . . . . 1510
75.11.456Write . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1510
75.11.457WriteBarrier . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1511
75.11.458WriteLn . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1511
75.11.459WriteStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1512
75.12 TDoubleRec . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1512
75.12.1 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1513
75.12.2 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1513
75.12.3 TDoubleRec.Mantissa . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1513
75.12.4 TDoubleRec.Fraction . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1514
75.12.5 TDoubleRec.Exponent . . . . . . . . . . . . . . . . . . . . . . . . . . . 1514
75.12.6 TDoubleRec.SpecialType . . . . . . . . . . . . . . . . . . . . . . . . . . 1514
75.12.7 TDoubleRec.Sign . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1514
75.12.8 TDoubleRec.Exp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1514
75.12.9 TDoubleRec.Frac . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1515
75.13 TExtended80Rec . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1515
75.13.1 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1516
75.13.2 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1516
75.13.3 TExtended80Rec.Mantissa . . . . . . . . . . . . . . . . . . . . . . . . . 1516
75.13.4 TExtended80Rec.Fraction . . . . . . . . . . . . . . . . . . . . . . . . . . 1516
75.13.5 TExtended80Rec.Exponent . . . . . . . . . . . . . . . . . . . . . . . . . 1516
75.13.6 TExtended80Rec.SpecialType . . . . . . . . . . . . . . . . . . . . . . . 1517
75.13.7 TExtended80Rec.Sign . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1517
75.13.8 TExtended80Rec.Exp . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1517
75.14 TSingleRec . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1517
75.14.1 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1518
75.14.2 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1518
75.14.3 TSingleRec.Mantissa . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1518
75.14.4 TSingleRec.Fraction . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1519
75.14.5 TSingleRec.Exponent . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1519
75.14.6 TSingleRec.SpecialType . . . . . . . . . . . . . . . . . . . . . . . . . . 1519
75.14.7 TSingleRec.Sign . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1519
92
CONTENTS
75.14.8 TSingleRec.Exp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1519
75.14.9 TSingleRec.Frac . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1520
75.15 IDispatch . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1520
75.15.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1520
75.15.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1520
75.15.3 IDispatch.GetTypeInfoCount . . . . . . . . . . . . . . . . . . . . . . . . 1520
75.15.4 IDispatch.GetTypeInfo . . . . . . . . . . . . . . . . . . . . . . . . . . . 1520
75.15.5 IDispatch.GetIDsOfNames . . . . . . . . . . . . . . . . . . . . . . . . . 1520
75.15.6 IDispatch.Invoke . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1521
75.16 IEnumerable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1521
75.16.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1521
75.16.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1521
75.16.3 IEnumerable.GetEnumerator . . . . . . . . . . . . . . . . . . . . . . . . 1521
75.17 IEnumerator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1521
75.17.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1521
75.17.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1522
75.17.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1522
75.17.4 IEnumerator.GetCurrent . . . . . . . . . . . . . . . . . . . . . . . . . . . 1522
75.17.5 IEnumerator.MoveNext . . . . . . . . . . . . . . . . . . . . . . . . . . . 1522
75.17.6 IEnumerator.Reset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1523
75.17.7 IEnumerator.Current . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1523
75.18 IInvokable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1523
75.18.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1523
75.19 IUnknown . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1523
75.19.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1523
75.19.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1524
75.19.3 IUnknown.QueryInterface . . . . . . . . . . . . . . . . . . . . . . . . . . 1524
75.19.4 IUnknown._AddRef . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1524
75.19.5 IUnknown._Release . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1524
75.20 TAggregatedObject . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1524
75.20.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1524
75.20.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1524
75.20.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1525
75.20.4 TAggregatedObject.Create . . . . . . . . . . . . . . . . . . . . . . . . . 1525
75.20.5 TAggregatedObject.Controller . . . . . . . . . . . . . . . . . . . . . . . 1525
75.21 TContainedObject . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1525
75.21.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1525
75.21.2 Interfaces overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1525
75.22 TInterfacedObject . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1526
75.22.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1526
93
CONTENTS
75.22.2 Interfaces overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1526
75.22.3 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1526
75.22.4 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1526
75.22.5 TInterfacedObject.AfterConstruction . . . . . . . . . . . . . . . . . . . . 1526
75.22.6 TInterfacedObject.BeforeDestruction . . . . . . . . . . . . . . . . . . . . 1526
75.22.7 TInterfacedObject.NewInstance . . . . . . . . . . . . . . . . . . . . . . . 1527
75.22.8 TInterfacedObject.RefCount . . . . . . . . . . . . . . . . . . . . . . . . 1527
75.23 TObject . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1527
75.23.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1527
75.23.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1528
75.23.3 TObject.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1528
75.23.4 TObject.Destroy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1529
75.23.5 TObject.newinstance . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1529
75.23.6 TObject.FreeInstance . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1529
75.23.7 TObject.SafeCallException . . . . . . . . . . . . . . . . . . . . . . . . . 1529
75.23.8 TObject.DefaultHandler . . . . . . . . . . . . . . . . . . . . . . . . . . . 1530
75.23.9 TObject.Free . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1530
75.23.10 TObject.InitInstance . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1530
75.23.11 TObject.CleanupInstance . . . . . . . . . . . . . . . . . . . . . . . . . . 1530
75.23.12 TObject.ClassType . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1531
75.23.13 TObject.ClassInfo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1531
75.23.14 TObject.ClassName . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1531
75.23.15 TObject.ClassNameIs . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1531
75.23.16 TObject.ClassParent . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1532
75.23.17 TObject.InstanceSize . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1532
75.23.18 TObject.InheritsFrom . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1532
75.23.19 TObject.StringMessageTable . . . . . . . . . . . . . . . . . . . . . . . . 1532
75.23.20 TObject.MethodAddress . . . . . . . . . . . . . . . . . . . . . . . . . . 1533
75.23.21 TObject.MethodName . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1533
75.23.22 TObject.FieldAddress . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1533
75.23.23 TObject.AfterConstruction . . . . . . . . . . . . . . . . . . . . . . . . . 1533
75.23.24 TObject.BeforeDestruction . . . . . . . . . . . . . . . . . . . . . . . . . 1534
75.23.25 TObject.DefaultHandlerStr . . . . . . . . . . . . . . . . . . . . . . . . . 1534
75.23.26 TObject.Dispatch . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1534
75.23.27 TObject.DispatchStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1534
75.23.28 TObject.GetInterface . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1535
75.23.29 TObject.GetInterfaceByStr . . . . . . . . . . . . . . . . . . . . . . . . . 1535
75.23.30 TObject.GetInterfaceWeak . . . . . . . . . . . . . . . . . . . . . . . . . 1535
75.23.31 TObject.GetInterfaceEntry . . . . . . . . . . . . . . . . . . . . . . . . . 1536
75.23.32 TObject.GetInterfaceEntryByStr . . . . . . . . . . . . . . . . . . . . . . 1536
94
CONTENTS
75.23.33 TObject.GetInterfaceTable . . . . . . . . . . . . . . . . . . . . . . . . . 1536
75.23.34 TObject.UnitName . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1536
75.23.35 TObject.Equals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1537
75.23.36 TObject.GetHashCode . . . . . . . . . . . . . . . . . . . . . . . . . . . 1537
75.23.37 TObject.ToString . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1537
76 Reference for unit ’sysutils’ 1538
76.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1538
76.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1538
76.3 Type Helpers for basic types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1538
76.4 Localization support . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1539
76.5 Unicode and codepage awareness . . . . . . . . . . . . . . . . . . . . . . . . . . . 1539
76.6 Miscellaneous conversion routines . . . . . . . . . . . . . . . . . . . . . . . . . . 1540
76.7 Date/time routines . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1541
76.8 FileName handling routines . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1541
76.9 File input/output routines . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1542
76.10 PChar related functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1543
76.11 Date and time formatting characters . . . . . . . . . . . . . . . . . . . . . . . . . . 1544
76.12 Formatting strings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1545
76.13 String functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1545
76.14 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1546
76.14.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1546
76.14.2 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1553
76.14.3 Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1564
76.15 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1569
76.15.1 AbandonSignalHandler . . . . . . . . . . . . . . . . . . . . . . . . . . . 1569
76.15.2 Abort . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1569
76.15.3 AddDisk . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1569
76.15.4 AddTerminateProc . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1570
76.15.5 AdjustLineBreaks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1570
76.15.6 AnsiCompareFileName . . . . . . . . . . . . . . . . . . . . . . . . . . . 1570
76.15.7 AnsiCompareStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1571
76.15.8 AnsiCompareText . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1572
76.15.9 AnsiDequotedStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1573
76.15.10 AnsiExtractQuotedStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1573
76.15.11 AnsiLastChar . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1574
76.15.12 AnsiLowerCase . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1574
76.15.13 AnsiLowerCaseFileName . . . . . . . . . . . . . . . . . . . . . . . . . . 1575
76.15.14 AnsiPos . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1575
76.15.15 AnsiQuotedStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1575
95
CONTENTS
76.15.16 AnsiSameStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1576
76.15.17 AnsiSameText . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1576
76.15.18 AnsiStrComp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1576
76.15.19 AnsiStrIComp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1577
76.15.20 AnsiStrLastChar . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1578
76.15.21 AnsiStrLComp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1579
76.15.22 AnsiStrLIComp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1579
76.15.23 AnsiStrLower . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1580
76.15.24 AnsiStrPos . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1581
76.15.25 AnsiStrRScan . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1581
76.15.26 AnsiStrScan . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1581
76.15.27 AnsiStrUpper . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1582
76.15.28 AnsiUpperCase . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1582
76.15.29 AnsiUpperCaseFileName . . . . . . . . . . . . . . . . . . . . . . . . . . 1583
76.15.30 AppendStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1583
76.15.31 ApplicationName . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1584
76.15.32 AssignStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1584
76.15.33 BCDToInt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1585
76.15.34 Beep . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1585
76.15.35 BoolToStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1585
76.15.36 ByteLength . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1586
76.15.37 BytesOf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1586
76.15.38 ByteToCharIndex . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1586
76.15.39 ByteToCharLen . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1586
76.15.40 ByteType . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1587
76.15.41 CallTerminateProcs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1587
76.15.42 ChangeFileExt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1587
76.15.43 CharInSet . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1587
76.15.44 CharToByteLen . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1588
76.15.45 CodePageNameToCodePage . . . . . . . . . . . . . . . . . . . . . . . . 1588
76.15.46 CodePageToCodePageName . . . . . . . . . . . . . . . . . . . . . . . . 1588
76.15.47 CompareMem . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1588
76.15.48 CompareMemRange . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1589
76.15.49 CompareStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1589
76.15.50 CompareText . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1590
76.15.51 ComposeDateTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1591
76.15.52 ConcatPaths . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1591
76.15.53 CreateDir . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1592
76.15.54 CreateGUID . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1592
76.15.55 CurrentYear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1593
96
CONTENTS
76.15.56 CurrToStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1593
76.15.57 CurrToStrF . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1593
76.15.58 Date . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1594
76.15.59 DateTimeToFileDate . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1594
76.15.60 DateTimeToStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1595
76.15.61 DateTimeToString . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1595
76.15.62 DateTimeToSystemTime . . . . . . . . . . . . . . . . . . . . . . . . . . 1596
76.15.63 DateTimeToTimeStamp . . . . . . . . . . . . . . . . . . . . . . . . . . . 1597
76.15.64 DateToStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1597
76.15.65 DayOfWeek . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1598
76.15.66 DecodeDate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1598
76.15.67 DecodeDateFully . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1599
76.15.68 DecodeTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1599
76.15.69 DeleteFile . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1600
76.15.70 DirectoryExists . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1600
76.15.71 DiskFree . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1601
76.15.72 DiskSize . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1601
76.15.73 DisposeStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1602
76.15.74 DoDirSeparators . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1602
76.15.75 EncodeDate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1603
76.15.76 EncodeTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1604
76.15.77 ExceptAddr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1604
76.15.78 ExceptFrameCount . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1604
76.15.79 ExceptFrames . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1605
76.15.80 ExceptionErrorMessage . . . . . . . . . . . . . . . . . . . . . . . . . . . 1605
76.15.81 ExceptObject . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1605
76.15.82 ExcludeLeadingPathDelimiter . . . . . . . . . . . . . . . . . . . . . . . 1606
76.15.83 ExcludeTrailingBackslash . . . . . . . . . . . . . . . . . . . . . . . . . . 1606
76.15.84 ExcludeTrailingPathDelimiter . . . . . . . . . . . . . . . . . . . . . . . 1606
76.15.85 ExecuteProcess . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1607
76.15.86 ExeSearch . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1607
76.15.87 ExpandFileName . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1608
76.15.88 ExpandFileNameCase . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1608
76.15.89 ExpandUNCFileName . . . . . . . . . . . . . . . . . . . . . . . . . . . 1609
76.15.90 ExtractFileDir . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1610
76.15.91 ExtractFileDrive . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1610
76.15.92 ExtractFileExt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1611
76.15.93 ExtractFileName . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1611
76.15.94 ExtractFilePath . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1611
76.15.95 ExtractRelativepath . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1612
97
CONTENTS
76.15.96 ExtractShortPathName . . . . . . . . . . . . . . . . . . . . . . . . . . . 1612
76.15.97 FileAge . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1613
76.15.98 FileClose . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1613
76.15.99 FileCreate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1614
76.15.100FileDateToDateTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1615
76.15.101FileExists . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1615
76.15.102FileGetAttr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1616
76.15.103FileGetDate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1617
76.15.104FileIsReadOnly . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1618
76.15.105FileOpen . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1618
76.15.106FileRead . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1619
76.15.107FileSearch . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1619
76.15.108FileSeek . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1620
76.15.109FileSetAttr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1621
76.15.110FileSetDate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1622
76.15.111FileTruncate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1622
76.15.112FileWrite . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1623
76.15.113FindClose . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1623
76.15.114FindCmdLineSwitch . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1623
76.15.115FindFirst . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1624
76.15.116FindNext . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1625
76.15.117FloattoCurr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1625
76.15.118FloatToDateTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1625
76.15.119FloatToDecimal . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1626
76.15.120FloatToStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1626
76.15.121FloatToStrF . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1627
76.15.122FloatToText . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1629
76.15.123FloatToTextFmt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1630
76.15.124FmtStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1631
76.15.125ForceDirectories . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1631
76.15.126Format . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1632
76.15.127FormatBuf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1638
76.15.128FormatCurr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1639
76.15.129FormatDateTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1639
76.15.130FormatFloat . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1640
76.15.131FreeAndNil . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1641
76.15.132FreeMemAndNil . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1642
76.15.133GetAppConfigDir . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1642
76.15.134GetAppConfigFile . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1643
76.15.135GetCurrentDir . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1643
98
CONTENTS
76.15.136GetDirs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1644
76.15.137GetDriveIDFromLetter . . . . . . . . . . . . . . . . . . . . . . . . . . . 1645
76.15.138GetEnvironmentString . . . . . . . . . . . . . . . . . . . . . . . . . . . 1645
76.15.139GetEnvironmentVariable . . . . . . . . . . . . . . . . . . . . . . . . . . 1645
76.15.140GetEnvironmentVariableCount . . . . . . . . . . . . . . . . . . . . . . . 1645
76.15.141GetFileHandle . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1646
76.15.142GetLastOSError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1646
76.15.143GetLocalTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1646
76.15.144GetLocalTimeOffset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1647
76.15.145GetModuleName . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1647
76.15.146GetTempDir . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1647
76.15.147GetTempFileName . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1648
76.15.148GetTickCount . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1648
76.15.149GetTickCount64 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1648
76.15.150GetUserDir . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1649
76.15.151GuidCase . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1649
76.15.152GUIDToString . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1649
76.15.153HashName . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1649
76.15.154HookSignal . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1650
76.15.155IncAMonth . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1650
76.15.156IncludeLeadingPathDelimiter . . . . . . . . . . . . . . . . . . . . . . . . 1650
76.15.157IncludeTrailingBackslash . . . . . . . . . . . . . . . . . . . . . . . . . . 1651
76.15.158IncludeTrailingPathDelimiter . . . . . . . . . . . . . . . . . . . . . . . . 1651
76.15.159IncMonth . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1651
76.15.160InquireSignal . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1652
76.15.161IntToHex . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1652
76.15.162IntToStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1653
76.15.163IsDelimiter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1654
76.15.164IsEqualGUID . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1654
76.15.165IsLeapYear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1654
76.15.166IsPathDelimiter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1655
76.15.167IsValidIdent . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1655
76.15.168LastDelimiter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1656
76.15.169LeftStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1656
76.15.170LoadStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1657
76.15.171LowerCase . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1657
76.15.172MSecsToTimeStamp . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1657
76.15.173NewStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1658
76.15.174Now . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1658
76.15.175OutOfMemoryError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1659
99
CONTENTS
76.15.176QuotedStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1659
76.15.177RaiseLastOSError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1660
76.15.178RemoveDir . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1660
76.15.179RenameFile . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1660
76.15.180ReplaceDate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1661
76.15.181ReplaceTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1661
76.15.182RightStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1662
76.15.183SafeLoadLibrary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1662
76.15.184SameFileName . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1662
76.15.185SameStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1663
76.15.186SameText . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1663
76.15.187SetCurrentDir . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1663
76.15.188SetDirSeparators . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1663
76.15.189ShowException . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1664
76.15.190Sleep . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1664
76.15.191SScanf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1664
76.15.192StrAlloc . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1665
76.15.193StrBufSize . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1665
76.15.194StrByteType . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1666
76.15.195strcat . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1666
76.15.196StrCharLength . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1667
76.15.197strcomp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1667
76.15.198StrCopy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1667
76.15.199StrDispose . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1668
76.15.200strecopy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1668
76.15.201strend . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1669
76.15.202StrFmt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1670
76.15.203stricomp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1670
76.15.204StringOf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1671
76.15.205StringReplace . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1671
76.15.206StringToGUID . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1671
76.15.207strlcat . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1672
76.15.208strlcomp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1672
76.15.209StrLCopy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1673
76.15.210StrLen . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1674
76.15.211StrLFmt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1674
76.15.212strlicomp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1675
76.15.213strlower . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1675
76.15.214StrMove . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1676
76.15.215strnew . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1677
100
CONTENTS
76.15.216StrNextChar . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1677
76.15.217StrPas . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1677
76.15.218StrPCopy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1678
76.15.219StrPLCopy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1678
76.15.220strpos . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1678
76.15.221strrscan . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1679
76.15.222StrScan . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1679
76.15.223StrToBool . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1680
76.15.224StrToBoolDef . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1680
76.15.225StrToCurr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1680
76.15.226StrToCurrDef . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1681
76.15.227StrToDate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1681
76.15.228StrToDateDef . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1682
76.15.229StrToDateTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1682
76.15.230StrToDateTimeDef . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1683
76.15.231StrToDWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1683
76.15.232StrToDWordDef . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1684
76.15.233StrToFloat . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1684
76.15.234StrToFloatDef . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1685
76.15.235StrToInt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1685
76.15.236StrToInt64 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1686
76.15.237StrToInt64Def . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1686
76.15.238StrToIntDef . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1687
76.15.239StrToQWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1687
76.15.240StrToQWordDef . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1688
76.15.241StrToTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1688
76.15.242StrToTimeDef . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1689
76.15.243strupper . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1689
76.15.244Supports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1689
76.15.245SysErrorMessage . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1690
76.15.246SystemTimeToDateTime . . . . . . . . . . . . . . . . . . . . . . . . . . 1690
76.15.247TextToFloat . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1691
76.15.248Time . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1692
76.15.249TimeStampToDateTime . . . . . . . . . . . . . . . . . . . . . . . . . . . 1692
76.15.250TimeStampToMSecs . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1693
76.15.251TimeToStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1693
76.15.252Trim . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1694
76.15.253TrimLeft . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1694
76.15.254TrimRight . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1695
76.15.255TryEncodeDate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1696
101
CONTENTS
76.15.256TryEncodeTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1696
76.15.257TryFloatToCurr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1697
76.15.258TryStringToGUID . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1697
76.15.259TryStrToBool . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1697
76.15.260TryStrToCurr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1697
76.15.261TryStrToDate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1698
76.15.262TryStrToDateTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1698
76.15.263TryStrToDWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1699
76.15.264TryStrToFloat . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1699
76.15.265TryStrToInt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1699
76.15.266TryStrToInt64 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1700
76.15.267TryStrToQWord . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1700
76.15.268TryStrToTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1700
76.15.269UnhookSignal . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1701
76.15.270UnicodeCompareStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1701
76.15.271UnicodeCompareText . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1701
76.15.272UnicodeFmtStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1701
76.15.273UnicodeFormat . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1701
76.15.274UnicodeFormatBuf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1702
76.15.275UnicodeLowerCase . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1702
76.15.276UnicodeSameStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1702
76.15.277UnicodeSameText . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1702
76.15.278UnicodeStringReplace . . . . . . . . . . . . . . . . . . . . . . . . . . . 1702
76.15.279UnicodeUpperCase . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1702
76.15.280UpperCase . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1703
76.15.281VendorName . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1703
76.15.282WideBytesOf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1703
76.15.283WideCompareStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1704
76.15.284WideCompareText . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1704
76.15.285WideFmtStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1704
76.15.286WideFormat . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1705
76.15.287WideFormatBuf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1705
76.15.288WideLowerCase . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1705
76.15.289WideSameStr . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1706
76.15.290WideSameText . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1706
76.15.291WideStrAlloc . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1706
76.15.292WideStringOf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1706
76.15.293WideStringReplace . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1706
76.15.294WideUpperCase . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1707
76.15.295WrapText . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1707
102
CONTENTS
76.16 EAbort . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1707
76.16.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1707
76.17 EAbstractError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1707
76.17.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1707
76.18 EAccessViolation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1708
76.18.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1708
76.19 EArgumentException . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1708
76.19.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1708
76.20 EArgumentNilException . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1708
76.20.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1708
76.21 EArgumentOutOfRangeException . . . . . . . . . . . . . . . . . . . . . . . . . . 1708
76.21.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1708
76.22 EAssertionFailed . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1708
76.22.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1708
76.23 EBusError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1709
76.23.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1709
76.24 EControlC . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1709
76.24.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1709
76.25 EConvertError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1709
76.25.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1709
76.26 EDirectoryNotFoundException . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1709
76.26.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1709
76.27 EDivByZero . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1709
76.27.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1709
76.28 EEncodingError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1709
76.29 EExternal . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1709
76.29.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1709
76.30 EExternalException . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1710
76.30.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1710
76.31 EFileNotFoundException . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1710
76.31.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1710
76.32 EFormatError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1710
76.32.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1710
76.33 EHeapMemoryError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1710
76.33.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1710
76.33.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1710
76.33.3 EHeapMemoryError.FreeInstance . . . . . . . . . . . . . . . . . . . . . 1710
76.34 EInOutError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1711
76.34.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1711
76.35 EInterror . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1711
103
CONTENTS
76.35.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1711
76.36 EIntfCastError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1711
76.36.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1711
76.37 EIntOverflow . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1711
76.37.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1711
76.38 EInvalidCast . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1711
76.38.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1711
76.39 EInvalidContainer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1711
76.39.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1711
76.40 EInvalidInsert . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1712
76.40.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1712
76.41 EInvalidOp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1712
76.41.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1712
76.42 EInvalidPointer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1712
76.42.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1712
76.43 EMathError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1712
76.43.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1712
76.44 ENoConstructException . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1712
76.44.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1712
76.45 ENoThreadSupport . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1712
76.45.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1712
76.46 ENotImplemented . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1712
76.46.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1712
76.47 ENotSupportedException . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1713
76.47.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1713
76.48 ENoWideStringSupport . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1713
76.48.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1713
76.49 EObjectCheck . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1713
76.49.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1713
76.50 EOSError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1713
76.50.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1713
76.51 EOutOfMemory . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1713
76.51.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1713
76.52 EOverflow . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1713
76.52.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1713
76.53 EPackageError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1714
76.53.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1714
76.54 EPathNotFoundException . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1714
76.54.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1714
76.55 EPathTooLongException . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1714
104
CONTENTS
76.55.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1714
76.56 EPrivilege . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1714
76.56.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1714
76.57 EPropReadOnly . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1714
76.57.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1714
76.58 EPropWriteOnly . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1714
76.58.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1714
76.59 ERangeError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1715
76.59.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1715
76.60 ESafecallException . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1715
76.60.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1715
76.61 EStackOverflow . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1715
76.61.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1715
76.62 EUnderflow . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1715
76.62.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1715
76.63 EVariantError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1715
76.63.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1715
76.63.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1715
76.63.3 EVariantError.CreateCode . . . . . . . . . . . . . . . . . . . . . . . . . . 1715
76.64 Exception . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1716
76.64.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1716
76.64.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1716
76.64.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1716
76.64.4 Exception.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1716
76.64.5 Exception.CreateFmt . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1717
76.64.6 Exception.CreateRes . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1717
76.64.7 Exception.CreateResFmt . . . . . . . . . . . . . . . . . . . . . . . . . . 1717
76.64.8 Exception.CreateHelp . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1717
76.64.9 Exception.CreateFmtHelp . . . . . . . . . . . . . . . . . . . . . . . . . . 1718
76.64.10 Exception.CreateResHelp . . . . . . . . . . . . . . . . . . . . . . . . . . 1718
76.64.11 Exception.CreateResFmtHelp . . . . . . . . . . . . . . . . . . . . . . . . 1718
76.64.12 Exception.ToString . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1718
76.64.13 Exception.HelpContext . . . . . . . . . . . . . . . . . . . . . . . . . . . 1719
76.64.14 Exception.Message . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1719
76.65 EZeroDivide . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1719
76.65.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1719
76.66 IReadWriteSync . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1719
76.66.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1719
76.66.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1719
76.66.3 IReadWriteSync.BeginRead . . . . . . . . . . . . . . . . . . . . . . . . 1720
105
CONTENTS
76.66.4 IReadWriteSync.EndRead . . . . . . . . . . . . . . . . . . . . . . . . . 1720
76.66.5 IReadWriteSync.BeginWrite . . . . . . . . . . . . . . . . . . . . . . . . 1720
76.66.6 IReadWriteSync.EndWrite . . . . . . . . . . . . . . . . . . . . . . . . . 1720
76.67 TBigEndianUnicodeEncoding . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1721
76.67.1 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1721
76.67.2 TBigEndianUnicodeEncoding.Clone . . . . . . . . . . . . . . . . . . . . 1721
76.67.3 TBigEndianUnicodeEncoding.GetPreamble . . . . . . . . . . . . . . . . 1721
76.68 TBooleanHelper . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1721
76.68.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1721
76.68.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1721
76.68.3 TBooleanHelper.Parse . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1721
76.68.4 TBooleanHelper.Size . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1722
76.68.5 TBooleanHelper.ToString . . . . . . . . . . . . . . . . . . . . . . . . . . 1722
76.68.6 TBooleanHelper.TryToParse . . . . . . . . . . . . . . . . . . . . . . . . 1722
76.68.7 TBooleanHelper.ToInteger . . . . . . . . . . . . . . . . . . . . . . . . . 1722
76.69 TByteBoolHelper . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1723
76.69.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1723
76.69.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1723
76.69.3 TByteBoolHelper.Parse . . . . . . . . . . . . . . . . . . . . . . . . . . . 1723
76.69.4 TByteBoolHelper.Size . . . . . . . . . . . . . . . . . . . . . . . . . . . 1723
76.69.5 TByteBoolHelper.ToString . . . . . . . . . . . . . . . . . . . . . . . . . 1724
76.69.6 TByteBoolHelper.TryToParse . . . . . . . . . . . . . . . . . . . . . . . . 1724
76.69.7 TByteBoolHelper.ToInteger . . . . . . . . . . . . . . . . . . . . . . . . . 1724
76.70 TByteHelper . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1724
76.70.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1724
76.70.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1725
76.70.3 TByteHelper.Parse . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1725
76.70.4 TByteHelper.Size . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1725
76.70.5 TByteHelper.ToString . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1725
76.70.6 TByteHelper.TryParse . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1726
76.70.7 TByteHelper.ToBoolean . . . . . . . . . . . . . . . . . . . . . . . . . . . 1726
76.70.8 TByteHelper.ToDouble . . . . . . . . . . . . . . . . . . . . . . . . . . . 1726
76.70.9 TByteHelper.ToExtended . . . . . . . . . . . . . . . . . . . . . . . . . . 1726
76.70.10 TByteHelper.ToHexString . . . . . . . . . . . . . . . . . . . . . . . . . . 1727
76.70.11 TByteHelper.ToSingle . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1727
76.71 TCardinalHelper . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1727
76.71.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1727
76.71.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1727
76.71.3 TCardinalHelper.Parse . . . . . . . . . . . . . . . . . . . . . . . . . . . 1728
76.71.4 TCardinalHelper.Size . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1728
106
CONTENTS
76.71.5 TCardinalHelper.ToString . . . . . . . . . . . . . . . . . . . . . . . . . . 1728
76.71.6 TCardinalHelper.TryParse . . . . . . . . . . . . . . . . . . . . . . . . . . 1728
76.71.7 TCardinalHelper.ToBoolean . . . . . . . . . . . . . . . . . . . . . . . . 1729
76.71.8 TCardinalHelper.ToDouble . . . . . . . . . . . . . . . . . . . . . . . . . 1729
76.71.9 TCardinalHelper.ToExtended . . . . . . . . . . . . . . . . . . . . . . . . 1729
76.71.10 TCardinalHelper.ToHexString . . . . . . . . . . . . . . . . . . . . . . . 1729
76.71.11 TCardinalHelper.ToSingle . . . . . . . . . . . . . . . . . . . . . . . . . 1730
76.72 TDoubleHelper . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1730
76.72.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1730
76.72.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1730
76.72.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1730
76.72.4 TDoubleHelper.IsInfinity . . . . . . . . . . . . . . . . . . . . . . . . . . 1730
76.72.5 TDoubleHelper.IsNan . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1731
76.72.6 TDoubleHelper.IsNegativeInfinity . . . . . . . . . . . . . . . . . . . . . 1731
76.72.7 TDoubleHelper.IsPositiveInfinity . . . . . . . . . . . . . . . . . . . . . . 1731
76.72.8 TDoubleHelper.Parse . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1732
76.72.9 TDoubleHelper.Size . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1732
76.72.10 TDoubleHelper.ToString . . . . . . . . . . . . . . . . . . . . . . . . . . 1732
76.72.11 TDoubleHelper.TryParse . . . . . . . . . . . . . . . . . . . . . . . . . . 1733
76.72.12 TDoubleHelper.BuildUp . . . . . . . . . . . . . . . . . . . . . . . . . . 1733
76.72.13 TDoubleHelper.Exponent . . . . . . . . . . . . . . . . . . . . . . . . . . 1734
76.72.14 TDoubleHelper.Fraction . . . . . . . . . . . . . . . . . . . . . . . . . . 1734
76.72.15 TDoubleHelper.Mantissa . . . . . . . . . . . . . . . . . . . . . . . . . . 1734
76.72.16 TDoubleHelper.SpecialType . . . . . . . . . . . . . . . . . . . . . . . . 1734
76.72.17 TDoubleHelper.Bytes . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1735
76.72.18 TDoubleHelper.Words . . . . . . . . . . . . . . . . . . . . . . . . . . . 1735
76.72.19 TDoubleHelper.Sign . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1735
76.72.20 TDoubleHelper.Exp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1735
76.72.21 TDoubleHelper.Frac . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1736
76.73 TEncoding . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1736
76.73.1 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1736
76.73.2 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1736
76.73.3 TEncoding.FreeEncodings . . . . . . . . . . . . . . . . . . . . . . . . . 1736
76.73.4 TEncoding.Clone . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1737
76.73.5 TEncoding.Convert . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1737
76.73.6 TEncoding.IsStandardEncoding . . . . . . . . . . . . . . . . . . . . . . 1737
76.73.7 TEncoding.GetBufferEncoding . . . . . . . . . . . . . . . . . . . . . . . 1737
76.73.8 TEncoding.GetEncoding . . . . . . . . . . . . . . . . . . . . . . . . . . 1737
76.73.9 TEncoding.GetMaxByteCount . . . . . . . . . . . . . . . . . . . . . . . 1737
76.73.10 TEncoding.GetMaxCharCount . . . . . . . . . . . . . . . . . . . . . . . 1738
107
CONTENTS
76.73.11 TEncoding.GetPreamble . . . . . . . . . . . . . . . . . . . . . . . . . . 1738
76.73.12 TEncoding.GetString . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1738
76.73.13 TEncoding.CodePage . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1738
76.73.14 TEncoding.EncodingName . . . . . . . . . . . . . . . . . . . . . . . . . 1738
76.73.15 TEncoding.IsSingleByte . . . . . . . . . . . . . . . . . . . . . . . . . . 1738
76.73.16 TEncoding.ANSI . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1738
76.73.17 TEncoding.ASCII . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1739
76.73.18 TEncoding.BigEndianUnicode . . . . . . . . . . . . . . . . . . . . . . . 1739
76.73.19 TEncoding.Default . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1739
76.73.20 TEncoding.Unicode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1739
76.73.21 TEncoding.UTF7 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1739
76.73.22 TEncoding.UTF8 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1739
76.74 TExtendedHelper . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1739
76.74.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1739
76.74.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1740
76.74.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1740
76.74.4 TExtendedHelper.ToString . . . . . . . . . . . . . . . . . . . . . . . . . 1740
76.74.5 TExtendedHelper.Parse . . . . . . . . . . . . . . . . . . . . . . . . . . . 1741
76.74.6 TExtendedHelper.TryParse . . . . . . . . . . . . . . . . . . . . . . . . . 1741
76.74.7 TExtendedHelper.IsNan . . . . . . . . . . . . . . . . . . . . . . . . . . . 1742
76.74.8 TExtendedHelper.IsInfinity . . . . . . . . . . . . . . . . . . . . . . . . . 1742
76.74.9 TExtendedHelper.IsNegativeInfinity . . . . . . . . . . . . . . . . . . . . 1742
76.74.10 TExtendedHelper.IsPositiveInfinity . . . . . . . . . . . . . . . . . . . . . 1742
76.74.11 TExtendedHelper.Size . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1743
76.74.12 TExtendedHelper.BuildUp . . . . . . . . . . . . . . . . . . . . . . . . . 1743
76.74.13 TExtendedHelper.Exponent . . . . . . . . . . . . . . . . . . . . . . . . . 1743
76.74.14 TExtendedHelper.Fraction . . . . . . . . . . . . . . . . . . . . . . . . . 1744
76.74.15 TExtendedHelper.Mantissa . . . . . . . . . . . . . . . . . . . . . . . . . 1744
76.74.16 TExtendedHelper.SpecialType . . . . . . . . . . . . . . . . . . . . . . . 1744
76.74.17 TExtendedHelper.Bytes . . . . . . . . . . . . . . . . . . . . . . . . . . . 1744
76.74.18 TExtendedHelper.Words . . . . . . . . . . . . . . . . . . . . . . . . . . 1745
76.74.19 TExtendedHelper.Sign . . . . . . . . . . . . . . . . . . . . . . . . . . . 1745
76.74.20 TExtendedHelper.Exp . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1745
76.74.21 TExtendedHelper.Frac . . . . . . . . . . . . . . . . . . . . . . . . . . . 1745
76.75 TGuidHelper . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1746
76.75.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1746
76.75.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1746
76.75.3 TGuidHelper.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1746
76.75.4 TGuidHelper.NewGuid . . . . . . . . . . . . . . . . . . . . . . . . . . . 1747
76.75.5 TGuidHelper.ToByteArray . . . . . . . . . . . . . . . . . . . . . . . . . 1747
108
CONTENTS
76.75.6 TGuidHelper.ToString . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1747
76.76 TInt64Helper . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1747
76.76.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1747
76.76.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1748
76.76.3 TInt64Helper.Parse . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1748
76.76.4 TInt64Helper.Size . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1748
76.76.5 TInt64Helper.ToString . . . . . . . . . . . . . . . . . . . . . . . . . . . 1748
76.76.6 TInt64Helper.TryParse . . . . . . . . . . . . . . . . . . . . . . . . . . . 1749
76.76.7 TInt64Helper.ToBoolean . . . . . . . . . . . . . . . . . . . . . . . . . . 1749
76.76.8 TInt64Helper.ToDouble . . . . . . . . . . . . . . . . . . . . . . . . . . . 1749
76.76.9 TInt64Helper.ToExtended . . . . . . . . . . . . . . . . . . . . . . . . . . 1749
76.76.10 TInt64Helper.ToHexString . . . . . . . . . . . . . . . . . . . . . . . . . 1750
76.76.11 TInt64Helper.ToSingle . . . . . . . . . . . . . . . . . . . . . . . . . . . 1750
76.77 TIntegerHelper . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1750
76.77.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1750
76.77.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1750
76.77.3 TIntegerHelper.Size . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1751
76.77.4 TIntegerHelper.ToString . . . . . . . . . . . . . . . . . . . . . . . . . . 1751
76.77.5 TIntegerHelper.Parse . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1751
76.77.6 TIntegerHelper.TryParse . . . . . . . . . . . . . . . . . . . . . . . . . . 1751
76.77.7 TIntegerHelper.ToBoolean . . . . . . . . . . . . . . . . . . . . . . . . . 1752
76.77.8 TIntegerHelper.ToDouble . . . . . . . . . . . . . . . . . . . . . . . . . . 1752
76.77.9 TIntegerHelper.ToExtended . . . . . . . . . . . . . . . . . . . . . . . . . 1752
76.77.10 TIntegerHelper.ToHexString . . . . . . . . . . . . . . . . . . . . . . . . 1752
76.77.11 TIntegerHelper.ToSingle . . . . . . . . . . . . . . . . . . . . . . . . . . 1753
76.78 TLongBoolHelper . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1753
76.78.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1753
76.78.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1753
76.78.3 TLongBoolHelper.Parse . . . . . . . . . . . . . . . . . . . . . . . . . . . 1753
76.78.4 TLongBoolHelper.Size . . . . . . . . . . . . . . . . . . . . . . . . . . . 1753
76.78.5 TLongBoolHelper.ToString . . . . . . . . . . . . . . . . . . . . . . . . . 1754
76.78.6 TLongBoolHelper.TryToParse . . . . . . . . . . . . . . . . . . . . . . . 1754
76.78.7 TLongBoolHelper.ToInteger . . . . . . . . . . . . . . . . . . . . . . . . 1754
76.79 TMBCSEncoding . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1755
76.79.1 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1755
76.79.2 TMBCSEncoding.Create . . . . . . . . . . . . . . . . . . . . . . . . . . 1755
76.79.3 TMBCSEncoding.Clone . . . . . . . . . . . . . . . . . . . . . . . . . . 1755
76.79.4 TMBCSEncoding.GetMaxByteCount . . . . . . . . . . . . . . . . . . . 1755
76.79.5 TMBCSEncoding.GetMaxCharCount . . . . . . . . . . . . . . . . . . . 1755
76.79.6 TMBCSEncoding.GetPreamble . . . . . . . . . . . . . . . . . . . . . . . 1755
109
CONTENTS
76.80 TMultiReadExclusiveWriteSynchronizer . . . . . . . . . . . . . . . . . . . . . . . 1755
76.80.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1755
76.80.2 Interfaces overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1756
76.80.3 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1756
76.80.4 TMultiReadExclusiveWriteSynchronizer.Create . . . . . . . . . . . . . . 1756
76.80.5 TMultiReadExclusiveWriteSynchronizer.Destroy . . . . . . . . . . . . . 1756
76.80.6 TMultiReadExclusiveWriteSynchronizer.Beginwrite . . . . . . . . . . . . 1756
76.80.7 TMultiReadExclusiveWriteSynchronizer.Endwrite . . . . . . . . . . . . . 1757
76.80.8 TMultiReadExclusiveWriteSynchronizer.Beginread . . . . . . . . . . . . 1757
76.80.9 TMultiReadExclusiveWriteSynchronizer.Endread . . . . . . . . . . . . . 1757
76.81 TNativeIntHelper . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1757
76.81.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1757
76.81.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1758
76.81.3 TNativeIntHelper.Parse . . . . . . . . . . . . . . . . . . . . . . . . . . . 1758
76.81.4 TNativeIntHelper.Size . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1758
76.81.5 TNativeIntHelper.ToString . . . . . . . . . . . . . . . . . . . . . . . . . 1758
76.81.6 TNativeIntHelper.TryParse . . . . . . . . . . . . . . . . . . . . . . . . . 1759
76.81.7 TNativeIntHelper.ToBoolean . . . . . . . . . . . . . . . . . . . . . . . . 1759
76.81.8 TNativeIntHelper.ToDouble . . . . . . . . . . . . . . . . . . . . . . . . . 1759
76.81.9 TNativeIntHelper.ToExtended . . . . . . . . . . . . . . . . . . . . . . . 1759
76.81.10 TNativeIntHelper.ToHexString . . . . . . . . . . . . . . . . . . . . . . . 1760
76.81.11 TNativeIntHelper.ToSingle . . . . . . . . . . . . . . . . . . . . . . . . . 1760
76.82 TNativeUIntHelper . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1760
76.82.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1760
76.82.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1760
76.82.3 TNativeUIntHelper.Parse . . . . . . . . . . . . . . . . . . . . . . . . . . 1761
76.82.4 TNativeUIntHelper.Size . . . . . . . . . . . . . . . . . . . . . . . . . . . 1761
76.82.5 TNativeUIntHelper.ToString . . . . . . . . . . . . . . . . . . . . . . . . 1761
76.82.6 TNativeUIntHelper.TryParse . . . . . . . . . . . . . . . . . . . . . . . . 1761
76.82.7 TNativeUIntHelper.ToBoolean . . . . . . . . . . . . . . . . . . . . . . . 1762
76.82.8 TNativeUIntHelper.ToDouble . . . . . . . . . . . . . . . . . . . . . . . . 1762
76.82.9 TNativeUIntHelper.ToExtended . . . . . . . . . . . . . . . . . . . . . . . 1762
76.82.10 TNativeUIntHelper.ToHexString . . . . . . . . . . . . . . . . . . . . . . 1762
76.82.11 TNativeUIntHelper.ToSingle . . . . . . . . . . . . . . . . . . . . . . . . 1763
76.83 TQWordHelper . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1763
76.83.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1763
76.83.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1763
76.83.3 TQWordHelper.Parse . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1763
76.83.4 TQWordHelper.Size . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1764
76.83.5 TQWordHelper.ToString . . . . . . . . . . . . . . . . . . . . . . . . . . 1764
110
CONTENTS
76.83.6 TQWordHelper.TryParse . . . . . . . . . . . . . . . . . . . . . . . . . . 1764
76.83.7 TQWordHelper.ToBoolean . . . . . . . . . . . . . . . . . . . . . . . . . 1764
76.83.8 TQWordHelper.ToDouble . . . . . . . . . . . . . . . . . . . . . . . . . . 1765
76.83.9 TQWordHelper.ToExtended . . . . . . . . . . . . . . . . . . . . . . . . . 1765
76.83.10 TQWordHelper.ToHexString . . . . . . . . . . . . . . . . . . . . . . . . 1765
76.83.11 TQWordHelper.ToSingle . . . . . . . . . . . . . . . . . . . . . . . . . . 1765
76.84 TShortIntHelper . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1766
76.84.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1766
76.84.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1766
76.84.3 TShortIntHelper.Parse . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1766
76.84.4 TShortIntHelper.Size . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1766
76.84.5 TShortIntHelper.ToString . . . . . . . . . . . . . . . . . . . . . . . . . . 1767
76.84.6 TShortIntHelper.TryParse . . . . . . . . . . . . . . . . . . . . . . . . . . 1767
76.84.7 TShortIntHelper.ToBoolean . . . . . . . . . . . . . . . . . . . . . . . . . 1767
76.84.8 TShortIntHelper.ToDouble . . . . . . . . . . . . . . . . . . . . . . . . . 1767
76.84.9 TShortIntHelper.ToExtended . . . . . . . . . . . . . . . . . . . . . . . . 1768
76.84.10 TShortIntHelper.ToHexString . . . . . . . . . . . . . . . . . . . . . . . . 1768
76.84.11 TShortIntHelper.ToSingle . . . . . . . . . . . . . . . . . . . . . . . . . . 1768
76.85 TSimpleRWSync . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1768
76.85.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1768
76.85.2 Interfaces overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1768
76.85.3 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1769
76.85.4 TSimpleRWSync.Create . . . . . . . . . . . . . . . . . . . . . . . . . . 1769
76.85.5 TSimpleRWSync.Destroy . . . . . . . . . . . . . . . . . . . . . . . . . . 1769
76.85.6 TSimpleRWSync.Beginwrite . . . . . . . . . . . . . . . . . . . . . . . . 1769
76.85.7 TSimpleRWSync.Endwrite . . . . . . . . . . . . . . . . . . . . . . . . . 1769
76.85.8 TSimpleRWSync.Beginread . . . . . . . . . . . . . . . . . . . . . . . . 1770
76.85.9 TSimpleRWSync.Endread . . . . . . . . . . . . . . . . . . . . . . . . . 1770
76.86 TSingleHelper . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1770
76.86.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1770
76.86.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1771
76.86.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1771
76.86.4 TSingleHelper.GetB . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1771
76.86.5 TSingleHelper.GetW . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1771
76.86.6 TSingleHelper.GetE . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1771
76.86.7 TSingleHelper.GetF . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1772
76.86.8 TSingleHelper.GetS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1772
76.86.9 TSingleHelper.SetB . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1772
76.86.10 TSingleHelper.SetW . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1772
76.86.11 TSingleHelper.SetE . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1772
111
CONTENTS
76.86.12 TSingleHelper.SetF . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1772
76.86.13 TSingleHelper.SetS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1772
76.86.14 TSingleHelper.IsNan . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1772
76.86.15 TSingleHelper.IsInfinity . . . . . . . . . . . . . . . . . . . . . . . . . . . 1773
76.86.16 TSingleHelper.IsNegativeInfinity . . . . . . . . . . . . . . . . . . . . . . 1773
76.86.17 TSingleHelper.IsPositiveInfinity . . . . . . . . . . . . . . . . . . . . . . 1773
76.86.18 TSingleHelper.Parse . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1774
76.86.19 TSingleHelper.Size . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1774
76.86.20 TSingleHelper.ToString . . . . . . . . . . . . . . . . . . . . . . . . . . . 1774
76.86.21 TSingleHelper.TryParse . . . . . . . . . . . . . . . . . . . . . . . . . . . 1775
76.86.22 TSingleHelper.BuildUp . . . . . . . . . . . . . . . . . . . . . . . . . . . 1775
76.86.23 TSingleHelper.Exponent . . . . . . . . . . . . . . . . . . . . . . . . . . 1775
76.86.24 TSingleHelper.Fraction . . . . . . . . . . . . . . . . . . . . . . . . . . . 1776
76.86.25 TSingleHelper.Mantissa . . . . . . . . . . . . . . . . . . . . . . . . . . . 1776
76.86.26 TSingleHelper.SpecialType . . . . . . . . . . . . . . . . . . . . . . . . . 1776
76.86.27 TSingleHelper.Bytes . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1776
76.86.28 TSingleHelper.Words . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1777
76.86.29 TSingleHelper.Sign . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1777
76.86.30 TSingleHelper.Exp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1777
76.86.31 TSingleHelper.Frac . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1777
76.87 TSmallIntHelper . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1778
76.87.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1778
76.87.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1778
76.87.3 TSmallIntHelper.Parse . . . . . . . . . . . . . . . . . . . . . . . . . . . 1778
76.87.4 TSmallIntHelper.Size . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1778
76.87.5 TSmallIntHelper.ToString . . . . . . . . . . . . . . . . . . . . . . . . . . 1779
76.87.6 TSmallIntHelper.TryParse . . . . . . . . . . . . . . . . . . . . . . . . . . 1779
76.87.7 TSmallIntHelper.ToBoolean . . . . . . . . . . . . . . . . . . . . . . . . 1779
76.87.8 TSmallIntHelper.ToHexString . . . . . . . . . . . . . . . . . . . . . . . 1779
76.87.9 TSmallIntHelper.ToSingle . . . . . . . . . . . . . . . . . . . . . . . . . 1780
76.87.10 TSmallIntHelper.ToDouble . . . . . . . . . . . . . . . . . . . . . . . . . 1780
76.87.11 TSmallIntHelper.ToExtended . . . . . . . . . . . . . . . . . . . . . . . . 1780
76.88 TStringHelper . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1780
76.88.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1780
76.88.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1782
76.88.3 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1783
76.88.4 TStringHelper.Compare . . . . . . . . . . . . . . . . . . . . . . . . . . . 1783
76.88.5 TStringHelper.CompareOrdinal . . . . . . . . . . . . . . . . . . . . . . . 1784
76.88.6 TStringHelper.CompareText . . . . . . . . . . . . . . . . . . . . . . . . 1784
76.88.7 TStringHelper.Copy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1784
112
CONTENTS
76.88.8 TStringHelper.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1785
76.88.9 TStringHelper.EndsText . . . . . . . . . . . . . . . . . . . . . . . . . . . 1785
76.88.10 TStringHelper.Equals . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1785
76.88.11 TStringHelper.Format . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1786
76.88.12 TStringHelper.IsNullOrEmpty . . . . . . . . . . . . . . . . . . . . . . . 1786
76.88.13 TStringHelper.IsNullOrWhiteSpace . . . . . . . . . . . . . . . . . . . . 1786
76.88.14 TStringHelper.Join . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1786
76.88.15 TStringHelper.LowerCase . . . . . . . . . . . . . . . . . . . . . . . . . . 1787
76.88.16 TStringHelper.Parse . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1787
76.88.17 TStringHelper.ToBoolean . . . . . . . . . . . . . . . . . . . . . . . . . . 1787
76.88.18 TStringHelper.ToDouble . . . . . . . . . . . . . . . . . . . . . . . . . . 1788
76.88.19 TStringHelper.ToExtended . . . . . . . . . . . . . . . . . . . . . . . . . 1788
76.88.20 TStringHelper.ToInt64 . . . . . . . . . . . . . . . . . . . . . . . . . . . 1788
76.88.21 TStringHelper.ToInteger . . . . . . . . . . . . . . . . . . . . . . . . . . 1789
76.88.22 TStringHelper.ToSingle . . . . . . . . . . . . . . . . . . . . . . . . . . . 1789
76.88.23 TStringHelper.UpperCase . . . . . . . . . . . . . . . . . . . . . . . . . . 1789
76.88.24 TStringHelper.CompareTo . . . . . . . . . . . . . . . . . . . . . . . . . 1790
76.88.25 TStringHelper.Contains . . . . . . . . . . . . . . . . . . . . . . . . . . . 1790
76.88.26 TStringHelper.CopyTo . . . . . . . . . . . . . . . . . . . . . . . . . . . 1790
76.88.27 TStringHelper.CountChar . . . . . . . . . . . . . . . . . . . . . . . . . . 1790
76.88.28 TStringHelper.DeQuotedString . . . . . . . . . . . . . . . . . . . . . . . 1791
76.88.29 TStringHelper.EndsWith . . . . . . . . . . . . . . . . . . . . . . . . . . 1791
76.88.30 TStringHelper.GetHashCode . . . . . . . . . . . . . . . . . . . . . . . . 1791
76.88.31 TStringHelper.IndexOf . . . . . . . . . . . . . . . . . . . . . . . . . . . 1791
76.88.32 TStringHelper.IndexOfUnQuoted . . . . . . . . . . . . . . . . . . . . . . 1792
76.88.33 TStringHelper.IndexOfAny . . . . . . . . . . . . . . . . . . . . . . . . . 1792
76.88.34 TStringHelper.IndexOfAnyUnquoted . . . . . . . . . . . . . . . . . . . . 1793
76.88.35 TStringHelper.Insert . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1793
76.88.36 TStringHelper.IsDelimiter . . . . . . . . . . . . . . . . . . . . . . . . . . 1794
76.88.37 TStringHelper.IsEmpty . . . . . . . . . . . . . . . . . . . . . . . . . . . 1794
76.88.38 TStringHelper.LastDelimiter . . . . . . . . . . . . . . . . . . . . . . . . 1794
76.88.39 TStringHelper.LastIndexOf . . . . . . . . . . . . . . . . . . . . . . . . . 1794
76.88.40 TStringHelper.LastIndexOfAny . . . . . . . . . . . . . . . . . . . . . . . 1795
76.88.41 TStringHelper.PadLeft . . . . . . . . . . . . . . . . . . . . . . . . . . . 1795
76.88.42 TStringHelper.PadRight . . . . . . . . . . . . . . . . . . . . . . . . . . . 1796
76.88.43 TStringHelper.QuotedString . . . . . . . . . . . . . . . . . . . . . . . . 1796
76.88.44 TStringHelper.Remove . . . . . . . . . . . . . . . . . . . . . . . . . . . 1796
76.88.45 TStringHelper.Replace . . . . . . . . . . . . . . . . . . . . . . . . . . . 1797
76.88.46 TStringHelper.Split . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1797
76.88.47 TStringHelper.StartsWith . . . . . . . . . . . . . . . . . . . . . . . . . . 1798
113
CONTENTS
76.88.48 TStringHelper.Substring . . . . . . . . . . . . . . . . . . . . . . . . . . 1798
76.88.49 TStringHelper.ToCharArray . . . . . . . . . . . . . . . . . . . . . . . . . 1799
76.88.50 TStringHelper.ToLower . . . . . . . . . . . . . . . . . . . . . . . . . . . 1799
76.88.51 TStringHelper.ToLowerInvariant . . . . . . . . . . . . . . . . . . . . . . 1799
76.88.52 TStringHelper.ToUpper . . . . . . . . . . . . . . . . . . . . . . . . . . . 1799
76.88.53 TStringHelper.ToUpperInvariant . . . . . . . . . . . . . . . . . . . . . . 1800
76.88.54 TStringHelper.Trim . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1800
76.88.55 TStringHelper.TrimLeft . . . . . . . . . . . . . . . . . . . . . . . . . . . 1800
76.88.56 TStringHelper.TrimRight . . . . . . . . . . . . . . . . . . . . . . . . . . 1800
76.88.57 TStringHelper.TrimEnd . . . . . . . . . . . . . . . . . . . . . . . . . . . 1801
76.88.58 TStringHelper.TrimStart . . . . . . . . . . . . . . . . . . . . . . . . . . 1801
76.88.59 TStringHelper.Chars . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1801
76.88.60 TStringHelper.Length . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1801
76.89 TUnicodeEncoding . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1802
76.89.1 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1802
76.89.2 TUnicodeEncoding.Create . . . . . . . . . . . . . . . . . . . . . . . . . 1802
76.89.3 TUnicodeEncoding.Clone . . . . . . . . . . . . . . . . . . . . . . . . . . 1802
76.89.4 TUnicodeEncoding.GetMaxByteCount . . . . . . . . . . . . . . . . . . . 1802
76.89.5 TUnicodeEncoding.GetMaxCharCount . . . . . . . . . . . . . . . . . . . 1802
76.89.6 TUnicodeEncoding.GetPreamble . . . . . . . . . . . . . . . . . . . . . . 1802
76.90 TUTF7Encoding . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1802
76.90.1 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1802
76.90.2 TUTF7Encoding.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . 1803
76.90.3 TUTF7Encoding.Clone . . . . . . . . . . . . . . . . . . . . . . . . . . . 1803
76.90.4 TUTF7Encoding.GetMaxByteCount . . . . . . . . . . . . . . . . . . . . 1803
76.90.5 TUTF7Encoding.GetMaxCharCount . . . . . . . . . . . . . . . . . . . . 1803
76.91 TUTF8Encoding . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1803
76.91.1 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1803
76.91.2 TUTF8Encoding.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . 1803
76.91.3 TUTF8Encoding.Clone . . . . . . . . . . . . . . . . . . . . . . . . . . . 1803
76.91.4 TUTF8Encoding.GetMaxByteCount . . . . . . . . . . . . . . . . . . . . 1803
76.91.5 TUTF8Encoding.GetMaxCharCount . . . . . . . . . . . . . . . . . . . . 1804
76.91.6 TUTF8Encoding.GetPreamble . . . . . . . . . . . . . . . . . . . . . . . 1804
76.92 TWordBoolHelper . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1804
76.92.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1804
76.92.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1804
76.92.3 TWordBoolHelper.Parse . . . . . . . . . . . . . . . . . . . . . . . . . . 1804
76.92.4 TWordBoolHelper.Size . . . . . . . . . . . . . . . . . . . . . . . . . . . 1804
76.92.5 TWordBoolHelper.ToString . . . . . . . . . . . . . . . . . . . . . . . . . 1805
76.92.6 TWordBoolHelper.TryToParse . . . . . . . . . . . . . . . . . . . . . . . 1805
114
CONTENTS
76.92.7 TWordBoolHelper.ToInteger . . . . . . . . . . . . . . . . . . . . . . . . 1805
76.93 TWordHelper . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1806
76.93.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1806
76.93.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1806
76.93.3 TWordHelper.Parse . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1806
76.93.4 TWordHelper.Size . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1806
76.93.5 TWordHelper.ToString . . . . . . . . . . . . . . . . . . . . . . . . . . . 1807
76.93.6 TWordHelper.TryParse . . . . . . . . . . . . . . . . . . . . . . . . . . . 1807
76.93.7 TWordHelper.ToBoolean . . . . . . . . . . . . . . . . . . . . . . . . . . 1807
76.93.8 TWordHelper.ToDouble . . . . . . . . . . . . . . . . . . . . . . . . . . . 1807
76.93.9 TWordHelper.ToExtended . . . . . . . . . . . . . . . . . . . . . . . . . . 1808
76.93.10 TWordHelper.ToHexString . . . . . . . . . . . . . . . . . . . . . . . . . 1808
76.93.11 TWordHelper.ToSingle . . . . . . . . . . . . . . . . . . . . . . . . . . . 1808
77 Reference for unit ’Types’ 1809
77.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1809
77.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1809
77.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1809
77.3.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1809
77.3.2 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1814
77.4 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1820
77.4.1 Bounds . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1820
77.4.2 CenterPoint . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1821
77.4.3 EqualRect . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1821
77.4.4 InflateRect . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1821
77.4.5 IntersectRect . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1821
77.4.6 IsRectEmpty . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1822
77.4.7 OffsetRect . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1822
77.4.8 Point . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1822
77.4.9 PtInRect . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1822
77.4.10 Rect . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1823
77.4.11 Size . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1823
77.4.12 UnionRect . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1823
77.5 TPoint . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1823
77.5.1 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1825
77.5.2 TPoint.Zero . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1825
77.5.3 TPoint.Add . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1825
77.5.4 TPoint.Distance . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1825
77.5.5 TPoint.IsZero . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1825
77.5.6 TPoint.Subtract . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1825
115
CONTENTS
77.5.7 TPoint.SetLocation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1825
77.5.8 TPoint.SetLocation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1826
77.5.9 TPoint.Offset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1826
77.5.10 TPoint.Offset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1826
77.5.11 TPoint.PointInCircle . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1826
77.5.12 TPoint.equal(TPoint,TPoint):Boolean . . . . . . . . . . . . . . . . . . . 1826
77.5.13 TPoint.notequal(TPoint,TPoint):Boolean . . . . . . . . . . . . . . . . . . 1826
77.5.14 TPoint.add(TPoint,TPoint):TPoint . . . . . . . . . . . . . . . . . . . . . 1826
77.5.15 TPoint.subtract(TPoint,TPoint):TPoint . . . . . . . . . . . . . . . . . . . 1826
77.5.16 TPoint.assign(TSmallPoint):TPoint . . . . . . . . . . . . . . . . . . . . . 1827
77.5.17 TPoint.explicit(TPoint):TSmallPoint . . . . . . . . . . . . . . . . . . . . 1827
77.6 TPointF . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1827
77.6.1 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1828
77.6.2 TPointF.Add . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1828
77.6.3 TPointF.Add . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1829
77.6.4 TPointF.Distance . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1829
77.6.5 TPointF.DotProduct . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1829
77.6.6 TPointF.IsZero . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1829
77.6.7 TPointF.Subtract . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1829
77.6.8 TPointF.Subtract . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1829
77.6.9 TPointF.SetLocation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1829
77.6.10 TPointF.SetLocation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1829
77.6.11 TPointF.SetLocation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1829
77.6.12 TPointF.Offset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1830
77.6.13 TPointF.Offset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1830
77.6.14 TPointF.Offset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1830
77.6.15 TPointF.Scale . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1830
77.6.16 TPointF.Ceiling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1830
77.6.17 TPointF.Truncate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1830
77.6.18 TPointF.Floor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1830
77.6.19 TPointF.Round . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1830
77.6.20 TPointF.Length . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1830
77.6.21 TPointF.equal(TPointF,TPointF):Boolean . . . . . . . . . . . . . . . . . 1831
77.6.22 TPointF.notequal(TPointF,TPointF):Boolean . . . . . . . . . . . . . . . . 1831
77.6.23 TPointF.add(TPointF,TPointF):TPointF . . . . . . . . . . . . . . . . . . 1831
77.6.24 TPointF.subtract(TPointF,TPointF):TPointF . . . . . . . . . . . . . . . . 1831
77.6.25 TPointF.negative(TPointF):TPointF . . . . . . . . . . . . . . . . . . . . . 1831
77.6.26 TPointF.multiply(TPointF,TPointF):Single . . . . . . . . . . . . . . . . . 1831
77.6.27 TPointF.multiply(TPointF,single):TPointF . . . . . . . . . . . . . . . . . 1831
77.6.28 TPointF.multiply(single,TPointF):TPointF . . . . . . . . . . . . . . . . . 1831
116
CONTENTS
77.7 TRect . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1832
77.7.1 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1834
77.7.2 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1834
77.7.3 TRect.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1834
77.7.4 TRect.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1834
77.7.5 TRect.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1834
77.7.6 TRect.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1834
77.7.7 TRect.Create . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1835
77.7.8 TRect.equal(TRect,TRect):Boolean . . . . . . . . . . . . . . . . . . . . . 1835
77.7.9 TRect.notequal(TRect,TRect):Boolean . . . . . . . . . . . . . . . . . . . 1835
77.7.10 TRect.add(TRect,TRect):TRect . . . . . . . . . . . . . . . . . . . . . . . 1835
77.7.11 TRect.multiply(TRect,TRect):TRect . . . . . . . . . . . . . . . . . . . . 1835
77.7.12 TRect.Empty . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1835
77.7.13 TRect.NormalizeRect . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1835
77.7.14 TRect.IsEmpty . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1835
77.7.15 TRect.Contains . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1835
77.7.16 TRect.Contains . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1836
77.7.17 TRect.IntersectsWith . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1836
77.7.18 TRect.Intersect . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1836
77.7.19 TRect.Intersect . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1836
77.7.20 TRect.Union . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1836
77.7.21 TRect.Union . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1836
77.7.22 TRect.Union . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1836
77.7.23 TRect.Offset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1836
77.7.24 TRect.Offset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1836
77.7.25 TRect.SetLocation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1837
77.7.26 TRect.SetLocation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1837
77.7.27 TRect.Inflate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1837
77.7.28 TRect.Inflate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1837
77.7.29 TRect.CenterPoint . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1837
77.7.30 TRect.SplitRect . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1837
77.7.31 TRect.SplitRect . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1837
77.7.32 TRect.Height . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1837
77.7.33 TRect.Width . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1838
77.7.34 TRect.Size . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1838
77.7.35 TRect.Location . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1838
77.8 TRectF . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1838
77.8.1 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1839
77.8.2 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1839
77.8.3 TRectF.Union . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1839
117
CONTENTS
77.8.4 TRectF.Offset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1839
77.8.5 TRectF.Width . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1839
77.8.6 TRectF.Height . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1839
77.9 TSize . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1839
77.9.1 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1840
77.9.2 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1840
77.9.3 TSize.Add . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1840
77.9.4 TSize.Distance . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1840
77.9.5 TSize.IsZero . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1840
77.9.6 TSize.Subtract . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1841
77.9.7 TSize.equal(TSize,TSize):Boolean . . . . . . . . . . . . . . . . . . . . . 1841
77.9.8 TSize.notequal(TSize,TSize):Boolean . . . . . . . . . . . . . . . . . . . 1841
77.9.9 TSize.add(TSize,TSize):TSize . . . . . . . . . . . . . . . . . . . . . . . 1841
77.9.10 TSize.subtract(TSize,TSize):TSize . . . . . . . . . . . . . . . . . . . . . 1841
77.9.11 TSize.Width . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1841
77.9.12 TSize.Height . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1841
77.10 IClassFactory . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1841
77.10.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1841
77.10.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1842
77.10.3 IClassFactory.CreateInstance . . . . . . . . . . . . . . . . . . . . . . . . 1842
77.10.4 IClassFactory.LockServer . . . . . . . . . . . . . . . . . . . . . . . . . . 1842
77.11 ISequentialStream . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1842
77.11.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1842
77.11.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1842
77.11.3 ISequentialStream.Read . . . . . . . . . . . . . . . . . . . . . . . . . . . 1842
77.11.4 ISequentialStream.Write . . . . . . . . . . . . . . . . . . . . . . . . . . 1843
77.12 IStream . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1843
77.12.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1843
77.12.2 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1843
77.12.3 IStream.Seek . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1843
77.12.4 IStream.SetSize . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1843
77.12.5 IStream.CopyTo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1844
77.12.6 IStream.Commit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1844
77.12.7 IStream.Revert . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1844
77.12.8 IStream.LockRegion . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1844
77.12.9 IStream.UnlockRegion . . . . . . . . . . . . . . . . . . . . . . . . . . . 1845
77.12.10 IStream.Stat . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1845
77.12.11 IStream.Clone . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1845
78 Reference for unit ’typinfo’ 1846
118
CONTENTS
78.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1846
78.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1846
78.3 Auxiliary functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1846
78.4 Getting or setting property values . . . . . . . . . . . . . . . . . . . . . . . . . . . 1847
78.5 Examining published property information . . . . . . . . . . . . . . . . . . . . . . 1847
78.6 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1848
78.6.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1848
78.6.2 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1849
78.7 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1865
78.7.1 FindPropInfo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1865
78.7.2 GetEnumName . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1866
78.7.3 GetEnumNameCount . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1867
78.7.4 GetEnumProp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1867
78.7.5 GetEnumValue . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1868
78.7.6 GetFloatProp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1868
78.7.7 GetInt64Prop . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1869
78.7.8 GetInterfaceProp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1870
78.7.9 GetMethodProp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1870
78.7.10 GetObjectProp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1872
78.7.11 GetObjectPropClass . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1873
78.7.12 GetOrdProp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1874
78.7.13 GetPropInfo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1875
78.7.14 GetPropInfos . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1875
78.7.15 GetPropList . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1876
78.7.16 GetPropValue . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1877
78.7.17 GetRawInterfaceProp . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1878
78.7.18 GetSetProp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1878
78.7.19 GetStrProp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1879
78.7.20 GetTypeData . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1880
78.7.21 GetUnicodeStrProp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1881
78.7.22 GetVariantProp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1881
78.7.23 GetWideStrProp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1881
78.7.24 IsPublishedProp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1882
78.7.25 IsStoredProp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1882
78.7.26 PropIsType . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1883
78.7.27 PropType . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1884
78.7.28 SetEnumProp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1885
78.7.29 SetFloatProp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1885
78.7.30 SetInt64Prop . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1886
78.7.31 SetInterfaceProp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1886
119
CONTENTS
78.7.32 SetMethodProp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1887
78.7.33 SetObjectProp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1887
78.7.34 SetOrdProp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1888
78.7.35 SetPropValue . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1888
78.7.36 SetRawInterfaceProp . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1888
78.7.37 SetSetProp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1889
78.7.38 SetStrProp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1889
78.7.39 SetToString . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1890
78.7.40 SetUnicodeStrProp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1891
78.7.41 SetVariantProp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1891
78.7.42 SetWideStrProp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1891
78.7.43 StringToSet . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1892
78.8 TProcedureSignature . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1892
78.8.1 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1892
78.8.2 TProcedureSignature.GetParam . . . . . . . . . . . . . . . . . . . . . . . 1892
78.9 EPropertyConvertError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1893
78.9.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1893
78.10 EPropertyError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1893
78.10.1 Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1893
79 Reference for unit ’unicodedata’ 1894
79.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1894
79.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1894
79.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1895
79.3.1 Resource strings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1895
79.3.2 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1895
79.3.3 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1898
79.4 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1900
79.4.1 CanonicalOrder . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1900
79.4.2 CompareSortKey . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1901
79.4.3 ComputeSortKey . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1901
79.4.4 FindCollation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1901
79.4.5 FreeCollation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1902
79.4.6 FromUCS4 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1902
79.4.7 GetCollationCount . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1902
79.4.8 GetProps . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1902
79.4.9 GetPropUCA . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1903
79.4.10 IncrementalCompareString . . . . . . . . . . . . . . . . . . . . . . . . . 1903
79.4.11 LoadCollation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1903
79.4.12 NormalizeNFD . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1904
120
CONTENTS
79.4.13 PrepareCollation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1904
79.4.14 RegisterCollation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1904
79.4.15 ToUCS4 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1905
79.4.16 UnicodeIsHighSurrogate . . . . . . . . . . . . . . . . . . . . . . . . . . 1905
79.4.17 UnicodeIsLowSurrogate . . . . . . . . . . . . . . . . . . . . . . . . . . 1905
79.4.18 UnicodeIsSurrogatePair . . . . . . . . . . . . . . . . . . . . . . . . . . . 1906
79.4.19 UnicodeToLower . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1906
79.4.20 UnicodeToUpper . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1906
79.4.21 UnregisterCollation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1907
79.4.22 UnregisterCollations . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1907
79.5 TUCA_DataBook . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1907
79.5.1 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1908
79.5.2 TUCA_DataBook.IsVariable . . . . . . . . . . . . . . . . . . . . . . . . 1908
79.6 TUCA_PropItemContextRec . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1908
79.6.1 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1908
79.6.2 TUCA_PropItemContextRec.GetCodePoints . . . . . . . . . . . . . . . . 1908
79.6.3 TUCA_PropItemContextRec.GetWeights . . . . . . . . . . . . . . . . . 1909
79.7 TUCA_PropItemContextTreeNodeRec . . . . . . . . . . . . . . . . . . . . . . . . 1909
79.7.1 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1909
79.7.2 TUCA_PropItemContextTreeNodeRec.GetLeftNode . . . . . . . . . . . 1909
79.7.3 TUCA_PropItemContextTreeNodeRec.GetRightNode . . . . . . . . . . . 1909
79.8 TUCA_PropItemContextTreeRec . . . . . . . . . . . . . . . . . . . . . . . . . . . 1909
79.8.1 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1910
79.8.2 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1910
79.8.3 TUCA_PropItemContextTreeRec.GetData . . . . . . . . . . . . . . . . . 1910
79.8.4 TUCA_PropItemContextTreeRec.Find . . . . . . . . . . . . . . . . . . . 1910
79.8.5 TUCA_PropItemContextTreeRec.Data . . . . . . . . . . . . . . . . . . . 1910
79.9 TUCA_PropItemRec . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1911
79.9.1 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1911
79.9.2 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1912
79.9.3 TUCA_PropItemRec.HasCodePoint . . . . . . . . . . . . . . . . . . . . 1912
79.9.4 TUCA_PropItemRec.IsValid . . . . . . . . . . . . . . . . . . . . . . . . 1912
79.9.5 TUCA_PropItemRec.GetWeightArray . . . . . . . . . . . . . . . . . . . 1912
79.9.6 TUCA_PropItemRec.GetSelfOnlySize . . . . . . . . . . . . . . . . . . . 1912
79.9.7 TUCA_PropItemRec.GetContextual . . . . . . . . . . . . . . . . . . . . 1912
79.9.8 TUCA_PropItemRec.GetContext . . . . . . . . . . . . . . . . . . . . . . 1913
79.9.9 TUCA_PropItemRec.IsDeleted . . . . . . . . . . . . . . . . . . . . . . . 1913
79.9.10 TUCA_PropItemRec.IsWeightCompress_1 . . . . . . . . . . . . . . . . 1913
79.9.11 TUCA_PropItemRec.IsWeightCompress_2 . . . . . . . . . . . . . . . . 1913
79.9.12 TUCA_PropItemRec.CodePoint . . . . . . . . . . . . . . . . . . . . . . 1913
121
CONTENTS
79.9.13 TUCA_PropItemRec.Contextual . . . . . . . . . . . . . . . . . . . . . . 1913
79.10 TUC_Prop . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1914
79.10.1 Property overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1914
79.10.2 TUC_Prop.Category . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1914
79.10.3 TUC_Prop.WhiteSpace . . . . . . . . . . . . . . . . . . . . . . . . . . . 1915
79.10.4 TUC_Prop.HangulSyllable . . . . . . . . . . . . . . . . . . . . . . . . . 1915
79.10.5 TUC_Prop.NumericValue . . . . . . . . . . . . . . . . . . . . . . . . . . 1915
79.11 TUInt24Rec . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1915
79.11.1 Method overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1919
79.11.2 TUInt24Rec.implicit(TUInt24Rec):Cardinal . . . . . . . . . . . . . . . . 1920
79.11.3 TUInt24Rec.implicit(TUInt24Rec):LongInt . . . . . . . . . . . . . . . . 1920
79.11.4 TUInt24Rec.implicit(TUInt24Rec):Word . . . . . . . . . . . . . . . . . . 1920
79.11.5 TUInt24Rec.implicit(TUInt24Rec):Byte . . . . . . . . . . . . . . . . . . 1920
79.11.6 TUInt24Rec.implicit(Cardinal):TUInt24Rec . . . . . . . . . . . . . . . . 1921
79.11.7 TUInt24Rec.equal(TUInt24Rec,TUInt24Rec):Boolean . . . . . . . . . . 1921
79.11.8 TUInt24Rec.equal(TUInt24Rec,Cardinal):Boolean . . . . . . . . . . . . 1921
79.11.9 TUInt24Rec.equal(Cardinal,TUInt24Rec):Boolean . . . . . . . . . . . . 1921
79.11.10 TUInt24Rec.equal(TUInt24Rec,LongInt):Boolean . . . . . . . . . . . . . 1921
79.11.11 TUInt24Rec.equal(LongInt,TUInt24Rec):Boolean . . . . . . . . . . . . . 1922
79.11.12 TUInt24Rec.equal(TUInt24Rec,Word):Boolean . . . . . . . . . . . . . . 1922
79.11.13 TUInt24Rec.equal(Word,TUInt24Rec):Boolean . . . . . . . . . . . . . . 1922
79.11.14 TUInt24Rec.equal(TUInt24Rec,Byte):Boolean . . . . . . . . . . . . . . 1922
79.11.15 TUInt24Rec.equal(Byte,TUInt24Rec):Boolean . . . . . . . . . . . . . . 1922
79.11.16 TUInt24Rec.notequal(TUInt24Rec,TUInt24Rec):Boolean . . . . . . . . . 1922
79.11.17 TUInt24Rec.notequal(TUInt24Rec,Cardinal):Boolean . . . . . . . . . . . 1923
79.11.18 TUInt24Rec.notequal(Cardinal,TUInt24Rec):Boolean . . . . . . . . . . . 1923
79.11.19 TUInt24Rec.greaterthan(TUInt24Rec,TUInt24Rec):Boolean . . . . . . . 1923
79.11.20 TUInt24Rec.greaterthan(TUInt24Rec,Cardinal):Boolean . . . . . . . . . 1923
79.11.21 TUInt24Rec.greaterthan(Cardinal,TUInt24Rec):Boolean . . . . . . . . . 1923
79.11.22 TUInt24Rec.greaterthanorequal(TUInt24Rec,TUInt24Rec):Boolean . . . 1924
79.11.23 TUInt24Rec.greaterthanorequal(TUInt24Rec,Cardinal):Boolean . . . . . 1924
79.11.24 TUInt24Rec.greaterthanorequal(Cardinal,TUInt24Rec):Boolean . . . . . 1924
79.11.25 TUInt24Rec.lessthan(TUInt24Rec,TUInt24Rec):Boolean . . . . . . . . . 1924
79.11.26 TUInt24Rec.lessthan(TUInt24Rec,Cardinal):Boolean . . . . . . . . . . . 1924
79.11.27 TUInt24Rec.lessthan(Cardinal,TUInt24Rec):Boolean . . . . . . . . . . . 1925
79.11.28 TUInt24Rec.lessthanorequal(TUInt24Rec,TUInt24Rec):Boolean . . . . . 1925
79.11.29 TUInt24Rec.lessthanorequal(TUInt24Rec,Cardinal):Boolean . . . . . . . 1925
79.11.30 TUInt24Rec.lessthanorequal(Cardinal,TUInt24Rec):Boolean . . . . . . . 1925
80 Reference for unit ’unicodeducet’ 1926
122
CONTENTS
80.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1926
80.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1926
81 Reference for unit ’Unix’ 1927
81.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1927
81.2 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1927
81.2.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1927
81.2.2 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1934
81.2.3 Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1943
81.3 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1943
81.3.1 AssignPipe . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1943
81.3.2 AssignStream . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1944
81.3.3 FpExecL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1945
81.3.4 FpExecLE . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1946
81.3.5 FpExecLP . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1947
81.3.6 FpExecLPE . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1948
81.3.7 FpExecV . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1948
81.3.8 FpExecVP . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1949
81.3.9 FpExecVPE . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1950
81.3.10 fpFlock . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1951
81.3.11 fpfStatFS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1951
81.3.12 fpfsync . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1952
81.3.13 fpgettimeofday . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1952
81.3.14 fpStatFS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1952
81.3.15 fpSystem . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1953
81.3.16 FSearch . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1953
81.3.17 GetDomainName . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1954
81.3.18 GetHostName . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1954
81.3.19 GetLocalTimezone . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1955
81.3.20 GetTimezoneFile . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1955
81.3.21 PClose . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1956
81.3.22 POpen . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1956
81.3.23 ReadTimezoneFile . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1957
81.3.24 ReReadLocalTime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1957
81.3.25 SeekDir . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1958
81.3.26 SelectText . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1958
81.3.27 SigRaise . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1958
81.3.28 TellDir . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1959
81.3.29 WaitProcess . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1959
81.3.30 WIFSTOPPED . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1960
123
CONTENTS
81.3.31 W_EXITCODE . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1960
81.3.32 W_STOPCODE . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1960
82 Reference for unit ’unixcp’ 1961
82.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1961
82.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1961
82.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1961
82.3.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1961
82.3.2 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1964
82.4 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1964
82.4.1 GetCodepageByName . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1964
82.4.2 GetCodepageData . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1965
82.4.3 GetSystemCodepage . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1965
83 Reference for unit ’unixtype’ 1966
83.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1966
83.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1966
83.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1966
83.3.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1966
83.3.2 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1968
84 Reference for unit ’unixutil’ 1981
84.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1981
84.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1981
84.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1981
84.3.1 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1981
84.3.2 Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1982
84.4 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1982
84.4.1 ArrayStringToPPchar . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1982
84.4.2 EpochToLocal . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1982
84.4.3 GetFS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1983
84.4.4 GregorianToJulian . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1984
84.4.5 JulianToGregorian . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1984
84.4.6 LocalToEpoch . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1984
84.4.7 StringToPPChar . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1985
85 Reference for unit ’video’ 1986
85.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1986
85.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1986
85.3 Examples utility unit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1987
85.4 Writing a custom video driver . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1988
124
CONTENTS
85.5 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1991
85.5.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1991
85.5.2 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1995
85.5.3 Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1997
85.6 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1997
85.6.1 ClearScreen . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1997
85.6.2 DefaultErrorHandler . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1998
85.6.3 DoneVideo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1998
85.6.4 GetCapabilities . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1999
85.6.5 GetCursorType . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2000
85.6.6 GetLockScreenCount . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2001
85.6.7 GetVideoDriver . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2001
85.6.8 GetVideoMode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2002
85.6.9 GetVideoModeCount . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2002
85.6.10 GetVideoModeData . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2004
85.6.11 InitVideo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2004
85.6.12 LockScreenUpdate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2004
85.6.13 SetCursorPos . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2005
85.6.14 SetCursorType . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2006
85.6.15 SetVideoDriver . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2006
85.6.16 SetVideoMode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2006
85.6.17 UnlockScreenUpdate . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2007
85.6.18 UpdateScreen . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2007
86 Reference for unit ’wincrt’ 2009
86.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2009
86.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2009
86.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2009
86.3.1 Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2009
86.4 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2009
86.4.1 delay . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2009
86.4.2 keypressed . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2010
86.4.3 nosound . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2010
86.4.4 readkey . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2010
86.4.5 sound . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2010
86.4.6 textmode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2011
87 Reference for unit ’windirs’ 2012
87.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2012
87.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2012
87.3 Constants, types and variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2012
125
CONTENTS
87.3.1 Constants . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2012
87.4 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2015
87.4.1 GetWindowsSpecialDir . . . . . . . . . . . . . . . . . . . . . . . . . . . 2015
87.4.2 GetWindowsSpecialDirUnicode . . . . . . . . . . . . . . . . . . . . . . 2016
87.4.3 GetWindowsSystemDirectory . . . . . . . . . . . . . . . . . . . . . . . . 2016
87.4.4 GetWindowsSystemDirectoryUnicode . . . . . . . . . . . . . . . . . . . 2016
88 Reference for unit ’x86’ 2017
88.1 Used units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2017
88.2 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2017
88.3 Procedures and functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2017
88.3.1 fpIOperm . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2017
88.3.2 fpIoPL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2018
88.3.3 ReadPort . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2018
88.3.4 ReadPortB . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2018
88.3.5 ReadPortL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2019
88.3.6 ReadPortW . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2019
88.3.7 WritePort . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2019
88.3.8 WritePortB . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2020
88.3.9 WritePortl . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2020
88.3.10 WritePortW . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2020
126
CONTENTS
About this guide
This document describes all constants, types, variables, functions and procedures as they are declared
in the units that come standard with the Free Pascal Run-Time library (RTL).
Throughout this document, we will refer to functions, types and variables with typewriter font.
Functions and procedures gave their own subsections, and for each function or procedure we have
the following topics:
Declaration The exact declaration of the function.
Description What does the procedure exactly do ?
Errors What errors can occur.
See Also Cross references to other related functions/commands.
0.1 Overview
The Run-Time Library is the basis of all Free Pascal programs. It contains the basic units that most
programs will use, and are made available on all platforms supported by Free pascal (well, more or
less).
There are units for compatibility with the Turbo Pascal Run-Time library, and there are units for
compatibility with Delphi.
On top of these two sets, there are also a series of units to handle keyboard/mouse and text screens
in a cross-platform way.
Other units include platform specific units that implement the specifics of a platform, these are usu-
ally needed to support the Turbo Pascal or Delphi units.
Units that fall outside the above outline do not belong in the RTL, but should be included in the
packages, or in the FCL.
127
Chapter 1
Reference for unit ’BaseUnix’
1.1 Used units
Table 1.1: Used units by unit ’BaseUnix’
Name Page
System 1280
unixtype 1966
1.2 Overview
The BaseUnix unit was implemented by Marco Van de Voort. It contains basic Unix functionality.
It supersedes the Linux unit of version 1.0.X of the compiler, but only implements a cleaned up,
portable subset of that unit.
For porting FPC to new Unix-like platforms, it should be sufficient to implement the functionality in
this unit for the new platform.
1.3 Constants, types and variables
1.3.1 Constants
ARG_MAX = UnixType.ARG_MAX
Maximum number of arguments to a program.
BITSINWORD = 8 * (cuLong)
Number of bits in a word.
ESysE2BIG = 7
System error: Argument list too long
ESysEACCES = 13
128
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
System error: Permission denied
ESysEADDRINUSE = 98
System error: Address already in use
ESysEADDRNOTAVAIL = 99
System error: Cannot assign requested address
ESysEADV = 68
System error: Advertise error
ESysEAFNOSUPPORT = 97
System error: Address family not supported by protocol
ESysEAGAIN = 11
System error: Try again
ESysEALREADY = 114
System error: Operation already in progress
ESysEBADE = 52
System error: Invalid exchange
ESysEBADF = 9
System error: Bad file number
ESysEBADFD = 77
System error: File descriptor in bad state
ESysEBADMSG = 74
System error: Not a data message
ESysEBADR = 53
System error: Invalid request descriptor
ESysEBADRQC = 56
System error: Invalid request code
ESysEBADSLT = 57
129
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
System error: Invalid slot
ESysEBFONT = 59
System error: Bad font file format
ESysEBUSY = 16
System error: Device or resource busy
ESysECANCELED = 125
Operation canceled
ESysECHILD = 10
System error: No child processes
ESysECHRNG = 44
System error: Channel number out of range
ESysECOMM = 70
System error: Communication error on send
ESysECONNABORTED = 103
System error: Software caused connection abort
ESysECONNREFUSED = 111
System error: Connection refused
ESysECONNRESET = 104
System error: Connection reset by peer
ESysEDEADLK = 35
System error: Resource deadlock would occur
ESysEDEADLOCK = ESysEDEADLK
System error: File locking deadlock error
ESysEDESTADDRREQ = 89
System error: Destination address required
ESysEDOM = 33
130
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
System error: Math argument out of domain of func
ESysEDOTDOT = 73
System error: RFS specific error
ESysEDQUOT = 122
System error: Quota exceeded
ESysEEXIST = 17
System error: File exists
ESysEFAULT = 14
System error: Bad address
ESysEFBIG = 27
System error: File too large
ESysEHOSTDOWN = 112
System error: Host is down
ESysEHOSTUNREACH = 113
System error: No route to host
ESysEIDRM = 43
System error: Identifier removed
ESysEILSEQ = 84
System error: Illegal byte sequence
ESysEINPROGRESS = 115
System error: Operation now in progress
ESysEINTR = 4
System error: Interrupted system call
ESysEINVAL = 22
System error: Invalid argument
ESysEIO = 5
131
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
System error: I/O error
ESysEISCONN = 106
System error: Transport endpoint is already connected
ESysEISDIR = 21
System error: Is a directory
ESysEISNAM = 120
System error: Is a named type file
ESysEKEYEXPIRED = 127
Key has expired (Linux kernel module)
ESysEKEYREJECTED = 129
Key was rejected by service (Linux kernel module)
ESysEKEYREVOKED = 128
Key has been revoked (Linux kernel module)
ESysEL2HLT = 51
System error: Level 2 halted
ESysEL2NSYNC = 45
System error: Level 2 not synchronized
ESysEL3HLT = 46
System error: Level 3 halted
ESysEL3RST = 47
System error: Level 3 reset
ESysELIBACC = 79
System error: Can not access a needed shared library
ESysELIBBAD = 80
System error: Accessing a corrupted shared library
ESysELIBEXEC = 83
132
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
System error: Cannot exec a shared library directly
ESysELIBMAX = 82
System error: Attempting to link in too many shared libraries
ESysELIBSCN = 81
System error: .lib section in a.out corrupted
ESysELNRNG = 48
System error: Link number out of range
ESysELOOP = 40
System error: Too many symbolic links encountered
ESysEMEDIUMTYPE = 124
Wrong medium type
ESysEMFILE = 24
System error: Too many open files
ESysEMLINK = 31
System error: Too many links
ESysEMSGSIZE = 90
System error: Message too long
ESysEMULTIHOP = 72
System error: Multihop attempted
ESysENAMETOOLONG = 36
System error: File name too long
ESysENAVAIL = 119
System error: No XENIX semaphores available
ESysENETDOWN = 100
System error: Network is down
ESysENETRESET = 102
133
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
System error: Network dropped connection because of reset
ESysENETUNREACH = 101
System error: Network is unreachable
ESysENFILE = 23
System error: File table overflow
ESysENOANO = 55
System error: No anode
ESysENOBUFS = 105
System error: No buffer space available
ESysENOCSI = 50
System error: No CSI structure available
ESysENODATA = 61
System error: No data available
ESysENODEV = 19
System error: No such device
ESysENOENT = 2
System error: No such file or directory
ESysENOEXEC = 8
System error: Exec format error
ESysENOKEY = 126
Required key not available (Linux kernel module)
ESysENOLCK = 37
System error: No record locks available
ESysENOLINK = 67
System error: Link has been severed
ESysENOMEDIUM = 123
134
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
No medium present
ESysENOMEM = 12
System error: Out of memory
ESysENOMSG = 42
System error: No message of desired type
ESysENONET = 64
System error: Machine is not on the network
ESysENOPKG = 65
System error: Package not installed
ESysENOPROTOOPT = 92
System error: Protocol not available
ESysENOSPC = 28
System error: No space left on device
ESysENOSR = 63
System error: Out of streams resources
ESysENOSTR = 60
System error: Device not a stream
ESysENOSYS = 38
System error: Function not implemented
ESysENOTBLK = 15
System error: Block device required
ESysENOTCONN = 107
System error: Transport endpoint is not connected
ESysENOTDIR = 20
System error: Not a directory
ESysENOTEMPTY = 39
135
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
System error: Directory not empty
ESysENOTNAM = 118
System error: Not a XENIX named type file
ESysENOTRECOVERABLE = 131
State not recoverable (mutexes)
ESysENOTSOCK = 88
System error: Socket operation on non-socket
ESysENOTTY = 25
System error: Not a typewriter
ESysENOTUNIQ = 76
System error: Name not unique on network
ESysENXIO = 6
System error: No such device or address
ESysEOPNOTSUPP = 95
System error: Operation not supported on transport endpoint
ESysEOVERFLOW = 75
System error: Value too large for defined data type
ESysEOWNERDEAD = 130
Owner died (mutexes)
ESysEPERM = 1
System error: Operation not permitted.
ESysEPFNOSUPPORT = 96
System error: Protocol family not supported
ESysEPIPE = 32
System error: Broken pipe
ESysEPROTO = 71
136
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
System error: Protocol error
ESysEPROTONOSUPPORT = 93
System error: Protocol not supported
ESysEPROTOTYPE = 91
System error: Protocol wrong type for socket
ESysERANGE = 34
System error: Math result not representable
ESysEREMCHG = 78
System error: Remote address changed
ESysEREMOTE = 66
System error: Object is remote
ESysEREMOTEIO = 121
System error: Remote I/O error
ESysERESTART = 85
System error: Interrupted system call should be restarted
ESysERFKILL = 132
Operation not possible due to RF-Kill (wireless)
ESysEROFS = 30
System error: Read-only file system
ESysESHUTDOWN = 108
System error: Cannot send after transport endpoint shutdown
ESysESOCKTNOSUPPORT = 94
System error: Socket type not supported
ESysESPIPE = 29
System error: Illegal seek
ESysESRCH = 3
137
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
System error: No such process
ESysESRMNT = 69
System error: Srmount error
ESysESTALE = 116
System error: Stale NFS file handle
ESysESTRPIPE = 86
System error: Streams pipe error
ESysETIME = 62
System error: Timer expired
ESysETIMEDOUT = 110
System error: Connection timed out
ESysETOOMANYREFS = 109
System error: Too many references: cannot splice
ESysETXTBSY = 26
System error: Text (code segment) file busy
ESysEUCLEAN = 117
System error: Structure needs cleaning
ESysEUNATCH = 49
System error: Protocol driver not attached
ESysEUSERS = 87
System error: Too many users
ESysEWOULDBLOCK = ESysEAGAIN
System error: Operation would block
ESysEXDEV = 18
System error: Cross-device link
ESysEXFULL = 54
138
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
System error: Exchange full
FD_MAXFDSET = 1024
Maximum elements in a TFDSet (164) array.
FPE_FLTDIV = 3
Value signalling floating point divide by zero in case of SIGFPE signal
FPE_FLTINV = 7
Value signalling floating point invalid operation in case of SIGFPE signal
FPE_FLTOVF = 4
Value signalling floating point overflow in case of SIGFPE signal
FPE_FLTRES = 6
Value signalling floating point inexact result in case of SIGFPE signal
FPE_FLTSUB = 8
Value signalling floating point subscript out of range in case of SIGFPE signal
FPE_FLTUND = 5
Value signalling floating point underflow in case of SIGFPE signal
FPE_INTDIV = 1
Value signalling integer divide in case of SIGFPE signal
FPE_INTOVF = 2
Value signalling integer overflow in case of SIGFPE signal
F_GetFd = 1
fpFCntl (180) command: Get close-on-exec flag
F_GetFl = 3
fpFCntl (180) command: Get filedescriptor flags
F_GetLk = 5
fpFCntl (180) command: Get lock
F_GetOwn = 9
139
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
fpFCntl (180) command: get owner of filedescriptor events
F_OK = 0
fpAccess (171) call test: file exists.
F_SetFd = 2
fpFCntl (180) command: Set close-on-exec flag
F_SetFl = 4
fpFCntl (180) command: Set filedescriptor flags
F_SetLk = 6
fpFCntl (180) command: Set lock
F_SetLkW = 7
fpFCntl (180) command: Test lock
F_SetOwn = 8
fpFCntl (180) command: Set owner of filedescriptor events
ln2bitmask = 1 shl ln2bitsinword - 1
Last bit in word.
ln2bitsinword = 5
Power of 2 number of bits in word.
MAP_ANON = MAP_ANONYMOUS
Anonymous memory mapping (data private to application)
MAP_ANONYMOUS = $20
FpMMap (193) map type: Don’t use a file
MAP_DENYWRITE = $800
FpMMap (193) option: Ignored.
MAP_EXECUTABLE = $1000
FpMMap (193) option: Ignored.
MAP_FAILED = (-1)
140
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
Memory mapping failed error code
MAP_FIXED = $10
FpMMap (193) map type: Interpret addr exactly
MAP_GROWSDOWN = $100
FpMMap (193) option: Memory grows downward (like a stack)
MAP_LOCKED = $2000
FpMMap (193) option: lock the pages in memory.
MAP_NORESERVE = $4000
FpMMap (193) option: Do not reserve swap pages for this memory.
MAP_PRIVATE = $2
FpMMap (193) map type: Changes are private
MAP_SHARED = $1
FpMMap (193) map type: Share changes
MAP_TYPE = $f
FpMMap (193) map type: Bitmask for type of mapping
NAME_MAX = UnixType.NAME_MAX
Maximum filename length.
O_APPEND = $400
fpOpen (197) file open mode: Append to file
O_CREAT = $40
fpOpen (197) file open mode: Create if file does not yet exist.
O_DIRECT = $4000
fpOpen (197) file open mode: Minimize caching effects
O_DIRECTORY = $10000
fpOpen (197) file open mode: File must be directory.
O_EXCL = $80
141
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
fpOpen (197) file open mode: Open exclusively
O_NDELAY = O_NONBLOCK
fpOpen (197) file open mode: Alias for O_NonBlock (142)
O_NOCTTY = $100
fpOpen (197) file open mode: No TTY control.
O_NOFOLLOW = $20000
fpOpen (197) file open mode: Fail if file is symbolic link.
O_NONBLOCK = $800
fpOpen (197) file open mode: Open in non-blocking mode
O_RDONLY = 0
fpOpen (197) file open mode: Read only
O_RDWR = 2
fpOpen (197) file open mode: Read/Write
O_SYNC = $1000
fpOpen (197) file open mode: Write to disc at once
O_TRUNC = $200
fpOpen (197) file open mode: Truncate file to length 0
O_WRONLY = 1
fpOpen (197) file open mode: Write only
PATH_MAX = UnixType.PATH_MAX
Maximum pathname length.
POLLERR = $0008
Error condition on output file descriptor
POLLHUP = $0010
Hang up
POLLIN = $0001
142
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
Data is available for reading
POLLNVAL = $0020
Invalid request, file descriptor not open.
POLLOUT = $0004
Writing data will not block the write call
POLLPRI = $0002
Urgent data is available for reading.
POLLRDBAND = $0080
Priority data ready for reading.
POLLRDNORM = $0040
Same as POLLIN.
POLLWRBAND = $0200
Priority data my be written.
POLLWRNORM = $0100
Equivalent to POLLOUT.
PRIO_PGRP = UnixType.PRIO_PGRP
Easy access alias for unixtype.PRIO_PGRP (1967)
PRIO_PROCESS = UnixType.PRIO_PROCESS
Easy access alias for unixtype.PRIO_PROCESS (1967)
PRIO_USER = UnixType.PRIO_USER
Easy access alias for unixtype.PRIO_USER (1967)
PROT_EXEC = $4
FpMMap (193) memory access: page can be executed
PROT_NONE = $0
FpMMap (193) memory access: page can not be accessed
PROT_READ = $1
143
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
FpMMap (193) memory access: page can be read
PROT_WRITE = $2
FpMMap (193) memory access: page can be written
RLIMIT_AS = 9
RLimit request address space limit
RLIMIT_CORE = 4
RLimit request max core file size
RLIMIT_CPU = 0
RLimit request CPU time in ms
RLIMIT_DATA = 2
RLimit request max data size
RLIMIT_FSIZE = 1
Rlimit request maximum filesize
RLIMIT_LOCKS = 10
RLimit request maximum file locks held
RLIMIT_MEMLOCK = 8
RLimit request max locked-in-memory address space
RLIMIT_NOFILE = 7
RLimit request max number of open files
RLIMIT_NPROC = 6
RLimit request max number of processes
RLIMIT_RSS = 5
RLimit request max resident set size
RLIMIT_STACK = 3
RLimit request max stack size
R_OK = 4
144
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
fpAccess (171) call test: read allowed
SA_INTERRUPT = $20000000
Sigaction options: ?
SA_NOCLDSTOP = 1
Sigaction options: Do not receive notification when child processes stop
SA_NOCLDWAIT = 2
Sigaction options: ?
SA_NODEFER = $40000000
Sigaction options: Do not mask signal in its own signal handler
SA_NOMASK = SA_NODEFER
Sigaction options: Do not prevent the signal from being received when it is handled.
SA_ONESHOT = SA_RESETHAND
Sigaction options: Restore the signal action to the default state.
SA_ONSTACK = $08000000
SA_ONSTACK is used in the fpsigaction (209) to indicate the signal handler must be called on an
alternate signal stack provided by sigaltstack(2) If an alternate stack is not available, the default
stack will be used.
SA_RESETHAND = $80000000
Sigaction options: Restore signal action to default state when signal handler exits.
SA_RESTART = $10000000
Sigaction options: Provide behaviour compatible with BSD signal semantics
SA_RESTORER = $04000000
Signal restorer handler
SA_SIGINFO = 4
Sigaction options: The signal handler takes 3 arguments, not one.
SEEK_CUR = 1
fpLSeek (191) option: Set position relative to current position.
145
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
SEEK_END = 2
fpLSeek (191) option: Set position relative to end of file.
SEEK_SET = 0
fpLSeek (191) option: Set absolute position.
SIGABRT = 6
Signal: ABRT (Abort)
SIGALRM = 14
Signal: ALRM (Alarm clock)
SIGBUS = 7
Signal: BUS (bus error)
SIGCHLD = 17
Signal: CHLD (child status changed)
SIGCONT = 18
Signal: CONT (Continue)
SIGFPE = 8
Signal: FPE (Floating point error)
SIGHUP = 1
Signal: HUP (Hangup)
SIGILL = 4
Signal: ILL (Illegal instruction)
SIGINT = 2
Signal: INT (Interrupt)
SIGIO = 29
Signal: IO (I/O operation possible)
SIGIOT = 6
Signal: IOT (IOT trap)
146
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
SIGKILL = 9
Signal: KILL (unblockable)
SIGPIPE = 13
Signal: PIPE (Broken pipe
SIGPOLL = SIGIO
Signal: POLL (Pollable event)
SIGPROF = 27
Signal: PROF (Profiling alarm)
SIGPWR = 30
Signal: PWR (power failure restart)
SIGQUIT = 3
Signal: QUIT
SIGSEGV = 11
Signal: SEGV (Segmentation violation)
SIGSTKFLT = 16
Signal: STKFLT (Stack Fault)
SIGSTOP = 19
Signal: STOP (Stop, unblockable)
SIGTERM = 15
Signal: TERM (Terminate)
SIGTRAP = 5
Signal: TRAP (Trace trap)
SIGTSTP = 20
Signal: TSTP (keyboard stop)
SIGTTIN = 21
Signal: TTIN (Terminal input, background)
147
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
SIGTTOU = 22
Signal: TTOU (Terminal output, background)
SIGUNUSED = 31
Signal: Unused
SIGURG = 23
Signal: URG (Socket urgent condition)
SIGUSR1 = 10
Signal: USR1 (User-defined signal 1)
SIGUSR2 = 12
Signal: USR2 (User-defined signal 2)
SIGVTALRM = 26
Signal: VTALRM (Virtual alarm clock)
SIGWINCH = 28
Signal: WINCH (Window/Terminal size change)
SIGXCPU = 24
Signal: XCPU (CPU limit exceeded)
SIGXFSZ = 25
Signal: XFSZ (File size limit exceeded)
SIG_BLOCK = 0
Sigprocmask flags: Add signals to the set of blocked signals.
SIG_DFL = 0
Signal handler: Default signal handler
SIG_ERR = -1
Signal handler: error
SIG_IGN = 1
Signal handler: Ignore signal
148
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
SIG_MAXSIG = UnixType.SIG_MAXSIG
Maximum system signal number.
SIG_SETMASK = 2
Sigprocmask flags: Set of blocked signals is given.
SIG_UNBLOCK = 1
Sigprocmask flags: Remove signals from the set set of blocked signals.
SI_PAD_SIZE = 128 div (longint) - 3
Signal information pad size.
SYS_NMLN = UnixType.SYS_NMLN
Max system name length.
S_IFBLK = 24576
File (#rtl.baseunix.stat (164) record) mode: Block device
S_IFCHR = 8192
File (#rtl.baseunix.stat (164) record) mode: Character device
S_IFDIR = 16384
File (#rtl.baseunix.stat (164) record) mode: Directory
S_IFIFO = 4096
File (#rtl.baseunix.stat (164) record) mode: FIFO
S_IFLNK = 40960
File (#rtl.baseunix.stat (164) record) mode: Link
S_IFMT = 61440
File (#rtl.baseunix.stat (164) record) mode: File type bit mask
S_IFREG = 32768
File (#rtl.baseunix.stat (164) record) mode: Regular file
S_IFSOCK = 49152
File (#rtl.baseunix.stat (164) record) mode: Socket
149
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
S_IRGRP = %0000100000
Mode flag: Read by group.
S_IROTH = %0000000100
Mode flag: Read by others.
S_IRUSR = %0100000000
Mode flag: Read by owner.
S_IRWXG = S_IRGRP or S_IWGRP or S_IXGRP
Mode flag: Read, write, execute by groups.
S_IRWXO = S_IROTH or S_IWOTH or S_IXOTH
Mode flag: Read, write, execute by others.
S_IRWXU = S_IRUSR or S_IWUSR or S_IXUSR
Mode flag: Read, write, execute by user.
S_IWGRP = %0000010000
Mode flag: Write by group.
S_IWOTH = %0000000010
Mode flag: Write by others.
S_IWUSR = %0010000000
Mode flag: Write by owner.
S_IXGRP = %0000001000
Mode flag: Execute by group.
S_IXOTH = %0000000001
Mode flag: Execute by others.
S_IXUSR = %0001000000
Mode flag: Execute by owner.
UTSNAME_DOMAIN_LENGTH = UTSNAME_LENGTH
Max length of utsname (170) domain name.
150
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
UTSNAME_LENGTH = SYS_NMLN
Max length of utsname (170) system name, release, version, machine.
UTSNAME_NODENAME_LENGTH = UTSNAME_LENGTH
Max length of utsname (170) node name.
WNOHANG = 1
#rtl.baseunix.fpWaitpid (222) option: Do not wait for processes to terminate.
wordsinfdset = FD_MAXFDSET div BITSINWORD
Number of words in a TFDSet (164) array
wordsinsigset = SIG_MAXSIG div BITSINWORD
Number of words in a signal set.
WUNTRACED = 2
#rtl.baseunix.fpWaitpid (222) option: Also report children wich were stopped but not yet reported
W_OK = 2
fpAccess (171) call test: write allowed
X_OK = 1
fpAccess (171) call test: execute allowed
_STAT_VER = _STAT_VER_LINUX
Stat version number
_STAT_VER_KERNEL = 0
Current version of stat record
_STAT_VER_LINUX = 1
Version of Linux stat record
1.3.2 Types
Blkcnt64_t = cuint64
64-bit block count
151
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
Blkcnt_t = cuint
Block count type.
Blksize_t = cuint
Block size type.
cbool = UnixType.cbool
Boolean type
cchar = UnixType.cchar
Alias for #rtl.UnixType.cchar (1968)
cdouble = UnixType.cdouble
Double precision real format.
cfloat = UnixType.cfloat
Floating-point real format
cint = UnixType.cint
C type: integer (natural size)
cint16 = UnixType.cint16
C type: 16 bits sized, signed integer.
cint32 = UnixType.cint32
C type: 32 bits sized, signed integer.
cint64 = UnixType.cint64
C type: 64 bits sized, signed integer.
cint8 = UnixType.cint8
C type: 8 bits sized, signed integer.
clock_t = UnixType.clock_t
Clock ticks type
clong = UnixType.clong
C type: long signed integer (double sized)
152
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
clonglong = UnixType.clonglong
C type: 64-bit (double long) signed integer.
coff_t = UnixType.TOff
Character offset type
cschar = UnixType.cschar
Signed character type
cshort = UnixType.cshort
C type: short signed integer (half sized)
csigned = UnixType.csigned
csigned is an alias for cint (152).
csint = UnixType.csint
Signed integer
csize_t = UnixType.size_t
Character size type
cslong = UnixType.cslong
The size is CPU dependent.
cslonglong = UnixType.cslonglong
cslonglong is an alias for clonglong (153).
csshort = UnixType.csshort
Short signed integer type
cuchar = UnixType.cuchar
Alias for #rtl.UnixType.cuchar (1969)
cuint = UnixType.cuint
C type: unsigned integer (natural size)
cuint16 = UnixType.cuint16
C type: 16 bits sized, unsigned integer.
153
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
cuint32 = UnixType.cuint32
C type: 32 bits sized, unsigned integer.
cuint64 = UnixType.cuint64
C type: 64 bits sized, unsigned integer.
cuint8 = UnixType.cuint8
C type: 8 bits sized, unsigned integer.
culong = UnixType.culong
C type: long unsigned integer (double sized)
culonglong = UnixType.culonglong
C type: 64-bit (double long) unsigned integer.
cunsigned = UnixType.cunsigned
Alias for #rtl.unixtype.cunsigned (1970)
cushort = UnixType.cushort
C type: short unsigned integer (half sized)
dev_t = UnixType.dev_t
Device descriptor type.
Dir = record
dd_fd : LongInt;
dd_loc : LongInt;
dd_size : LongInt
;
dd_buf : pDirent;
dd_nextoff : Cardinal;
dd_max : Integer
;
dd_lock : pointer;
end
Record used in fpOpenDir (198) and fpReadDir (202) calls
Dirent = record
d_fileno : ino64_t;
d_off : off_t;
d_reclen
: cushort;
d_type : cuchar;
d_name : Array[0..4095-sizeof(ino64_t
)-sizeof(off_t)-sizeof(cushort)-sizeof(cuchar)] of Char;
end
154
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
Record used in the fpReadDir (202) function to return files in a directory.
FLock = record
l_type : cshort;
l_whence : cshort;
l_start
: kernel_off_t;
l_len : kernel_off_t;
l_pid : pid_t;
end
Lock description type for fpFCntl (180) lock call.
gid_t = UnixType.gid_t
Group ID type.
ino_t = UnixType.ino_t
Inode type.
iovec = record
iov_base : pointer;
iov_len : size_t;
end
iovec is used in fpreadv (204) for IO to multiple buffers to describe a buffer location.
kernel_gid_t = cuint
kernel_gid_t may differ from the libc type used to describe group IDs.
kernel_loff_t = clonglong
Long kernel offset type
kernel_mode_t = cuint
kernel_mode_t may differ from the libc type used to describe file modes.
kernel_off_t = clong
Kernel offset type
kernel_uid_t = cuint
kernel_uid_t may differ from the libc type used to describe user IDs.
mode_t = UnixType.mode_t
155
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
Inode mode type.
nlink_t = UnixType.nlink_t
Number of links type.
off_t = UnixType.off_t
Offset type.
PBlkCnt = ^Blkcnt_t
pointer to TBlkCnt (164) type.
PBlkSize = ^Blksize_t
Pointer to TBlkSize (164) type.
pcbool = UnixType.pcbool
Pointer to boolean type cbool (152)
pcchar = UnixType.pcchar
Alias for #rtl.UnixType.pcchar (1971)
pcdouble = UnixType.pcdouble
Pointer to cdouble (152) type.
pcfloat = UnixType.pcfloat
Pointer to cfloat (152) type.
pcint = UnixType.pcint
Pointer to cInt (152) type.
pcint16 = UnixType.pcint16
Pointer to 16-bit signed integer type
pcint32 = UnixType.pcint32
Pointer to signed 32-bit integer type
pcint64 = UnixType.pcint64
Pointer to signed 64-bit integer type
pcint8 = UnixType.pcint8
156
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
Pointer to 8-bits signed integer type
pClock = UnixType.pClock
Pointer to TClock (164) type.
pclong = UnixType.pclong
Pointer to cLong (152) type.
pclonglong = UnixType.pclonglong
Pointer to longlong type.
pcschar = UnixType.pcschar
Pointer to character type cschar (153).
pcshort = UnixType.pcshort
Pointer to cShort (153) type.
pcsigned = UnixType.pcsigned
Pointer to signed integer type csigned (153).
pcsint = UnixType.pcsint
Pointer to signed integer type csint (153)
pcsize_t = UnixType.psize_t
Pointer to csize_t
pcslong = UnixType.pcslong
Pointer ot the signed long cslong (153)
pcslonglong = UnixType.pcslonglong
Pointer to Signed longlong type cslonglong (153)
pcsshort = UnixType.pcsshort
Pointer to short signed integer type csshort (153)
pcuchar = UnixType.pcuchar
Alias for #rtl.UnixType.pcuchar (1973)
pcuint = UnixType.pcuint
157
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
Pointer to cUInt (153) type.
pcuint16 = UnixType.pcuint16
Pointer to 16-bit unsigned integer type
pcuint32 = UnixType.pcuint32
Pointer to unsigned 32-bit integer type
pcuint64 = UnixType.pcuint64
Pointer to unsigned 64-bit integer type
pcuint8 = UnixType.pcuint8
Pointer to 8-bits unsigned integer type
pculong = UnixType.pculong
Pointer to cuLong (154) type.
pculonglong = UnixType.pculonglong
Unsigned longlong type
pcunsigned = UnixType.pcunsigned
Alias for #rtl.unixtype.pcunsigned (1973)
pcushort = UnixType.pcushort
Pointer to cuShort (154) type.
pDev = UnixType.pDev
Pointer to TDev (164) type.
pDir = ^Dir
Pointer to TDir (164) record
pDirent = ^Dirent
Pointer to TDirent (164) record.
pFDSet = ^TFDSet
Pointer to TFDSet (164) type.
pFilDes = ^TFilDes
158
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
Pointer to TFilDes (164) type.
pfpstate = ^tfpstate
Pointer to tfpstate (165) record.
pGid = UnixType.pGid
Pointer to TGid (165) type.
pGrpArr = ^TGrpArr
Pointer to TGrpArr (165) array.
pid_t = UnixType.pid_t
Process ID type.
pIno = UnixType.pIno
Pointer to TIno (165) type.
piovec = ^tiovec
pointer to a iovec (155) record
pMode = UnixType.pMode
Pointer to TMode (166) type.
pnLink = UnixType.pnLink
Pointer to TnLink (166) type.
pOff = UnixType.pOff
Pointer to TOff (166) type.
pollfd = record
fd : cint;
events : cshort;
revents : cshort
;
end
pollfd is used in the fpPoll (200) call to describe the various actions.
pPid = UnixType.pPid
Pointer to TPid (166) type.
159
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
ppollfd = ^pollfd
Pointer to tpollfd.
PRLimit = ^TRLimit
Pointer to TRLimit (166) record
psigactionrec = ^sigactionrec
Pointer to SigActionRec (162) record type.
PSigContext = ^TSigContext
Pointer to #rtl.baseunix.TSigContext (167) record type.
psiginfo = ^tsiginfo
Pointer to #rtl.baseunix.TSigInfo (168) record type.
psigset = ^tsigset
Pointer to SigSet (162) type.
pSize = UnixType.pSize
Pointer to TSize (169) type.
pSize_t = UnixType.pSize_t
Pointer to Size_t
pSocklen = UnixType.pSocklen
Pointer to TSockLen (169) type.
psSize = UnixType.psSize
Pointer to TsSize (169) type
PStat = ^Stat
Pointer to TStat (169) type.
pstatfs = UnixType.PStatFs
This is an alias for the type defined in the #rtl.unixtype (1966) unit.
pthread_cond_t = UnixType.pthread_cond_t
Thread conditional variable type.
160
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
pthread_mutex_t = UnixType.pthread_mutex_t
Thread mutex type.
pthread_t = UnixType.pthread_t
Posix thread type.
pTime = UnixType.pTime
Pointer to TTime (169) type.
ptimespec = UnixType.ptimespec
Pointer to timespec (165) type.
ptimeval = UnixType.ptimeval
Pointer to timeval (165) type.
ptimezone = ^timezone
Pointer to TimeZone (165) record.
ptime_t = UnixType.ptime_t
Pointer to time_t (165) type.
PTms = ^tms
Pointer to TTms (169) type.
Pucontext = ^Tucontext
Pointer to TUContext (170) type.
pUid = UnixType.pUid
Pointer to TUid (170) type.
pUtimBuf = ^UTimBuf
Pointer to TUTimBuf (170) type.
PUtsName = ^TUtsName
Pointer to TUtsName (170) type.
rlim_t = culong
rlim_t is used as the type for the various fields in the TRLimit (166) record.
161
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
sigactionhandler = sigactionhandler_t
When installing a signal handler, the actual signal handler must be of type SigActionHandler.
sigactionhandler_t = procedure(signal: LongInt; info: psiginfo;
context: PSigContext)
Standard signal action handler prototype
sigactionrec = record
sa_handler : sigactionhandler_t;
sa_flags
: culong;
sa_restorer : sigrestorerhandler_t;
sa_mask : sigset_t
;
end
Record used in fpSigAction (209) call.
signalhandler = signalhandler_t
Simple signal handler prototype
signalhandler_t = procedure(signal: LongInt)
Standard signal handler prototype
sigrestorerhandler = sigrestorerhandler_t
Alias for sigrestorerhandler_t (162) type.
sigrestorerhandler_t = procedure
Standard signal action restorer prototype
sigset = sigset_t
Signal set type
sigset_t = Array[0..wordsinsigset-1] of culong
Signal set type
size_t = UnixType.size_t
Size specification type.
socklen_t = UnixType.socklen_t
Socket address length type.
162
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
ssize_t = UnixType.ssize_t
Small size type.
Stat = packed record
case Byte of
0: (
dev : QWorddeprecated;
__pad0 : Array[0..3] of Bytedeprecated;
__ino : Cardinaldeprecated
;
mode : Cardinaldeprecated;
nlink : Cardinaldeprecated;
uid
: Cardinaldeprecated;
gid : Cardinaldeprecated;
rdev : QWorddeprecated
;
__pad3 : Array[0..3] of Bytedeprecated;
size : QWorddeprecated
;
blksize : Cardinaldeprecated;
blocks : QWorddeprecated;
atime
: Cardinaldeprecated;
atime_nsec : Cardinaldeprecated;
mtime
: Cardinaldeprecated;
mtime_nsec : Cardinaldeprecated;
ctime
: Cardinaldeprecated;
ctime_nsec : Cardinaldeprecated;
ino :
QWorddeprecated;
);
1: (
st_dev : QWord;
__pad0_ : Array[0..3
] of Byte;
__st_ino_ : Cardinal;
st_mode : Cardinal;
st_nlink
: Cardinal;
st_uid : Cardinal;
st_gid : Cardinal;
st_rdev
: QWord;
__pad3_ : Array[0..3] of Byte;
st_size : QWord;
st_blksize
: Cardinal;
st_blocks : QWord;
st_atime : Cardinal;
st_atime_nsec
163
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
: Cardinal;
st_mtime : Cardinal;
st_mtime_nsec : Cardinal;
st_ctime : Cardinal;
st_ctime_nsec : Cardinal;
st_ino : QWord
;
);
end
Record describing an inode (file) in the FPFstat (182) call.
TBlkCnt = Blkcnt_t
Alias for Blkcnt_t (152) type.
TBlkSize = Blksize_t
Alias for blksize_t (152) type.
TClock = UnixType.TClock
Alias for clock_t (152) type.
TDev = UnixType.TDev
Alias for dev_t (154) type.
TDir = Dir
Alias for Dir (154) type.
TDirent = Dirent
Alias for Dirent (155) type.
TFDSet = Array[0..(FD_MAXFDSETdivBITSINWORD)-1] of culong
File descriptor set for fpSelect (205) call.
TFilDes = Array[0..1] of cint
Array of file descriptors as used in fpPipe (199) call.
tfpreg = record
significand : Array[0..3] of Word;
exponent :
Word;
end
Record describing floating point register in signal handler.
164
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
tfpstate = record
cw : Cardinal;
sw : Cardinal;
tag : Cardinal
;
ipoff : Cardinal;
cssel : Cardinal;
dataoff : Cardinal;
datasel : Cardinal;
st : Array[0..7] of tfpreg;
status : Cardinal
;
end
Record describing floating point unit in signal handler.
TGid = UnixType.TGid
Alias for gid_t (155) type.
TGrpArr = Array[0..0] of TGid
Array of gid_t (155) IDs
timespec = UnixType.timespec
Short time specification type.
timeval = UnixType.timeval
Time specification type.
timezone = record
tz_minuteswest : cint;
tz_dsttime : cint;
end
Record describing a timezone
time_t = UnixType.time_t
Time span type
TIno = UnixType.TIno
Alias for ino_t (155) type.
TIOCtlRequest = UnixType.TIOCtlRequest
Easy access alias for unixtype.TIOCtlRequest (1978)
165
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
tiovec = iovec
Alias for the iovec (155) record type.
TMode = UnixType.TMode
Alias for mode_t (156) type.
tms = record
tms_utime : clock_t;
tms_stime : clock_t;
tms_cutime
: clock_t;
tms_cstime : clock_t;
end
Record containing timings for fpTimes (219) call.
TnLink = UnixType.TnLink
Alias for nlink_t (156) type.
TOff = UnixType.TOff
Alias for off_t (156) type.
TPid = UnixType.TPid
Alias for pid_t (159) type.
tpollfd = pollfd
Alias for pollfd type
TRLimit = record
rlim_cur : rlim_t;
rlim_max : rlim_t;
end
TRLimit is the structure used by the kernel to return resource limit information in.
tsigactionhandler = sigactionhandler_t
Alias for sigactionhandler_t (162) type.
tsigaltstack = record
ss_sp : pointer;
ss_flags : LongInt;
ss_size
: LongInt;
end
166
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
Provide the location of an alternate signal handler stack.
TSigContext = record
gs : Word;
__gsh : Word;
fs : Word;
__fsh
: Word;
es : Word;
__esh : Word;
ds : Word;
__dsh : Word
;
edi : Cardinal;
esi : Cardinal;
ebp : Cardinal;
esp : Cardinal
;
ebx : Cardinal;
edx : Cardinal;
ecx : Cardinal;
eax : Cardinal
;
trapno : Cardinal;
err : Cardinal;
eip : Cardinal;
cs :
Word;
__csh : Word;
eflags : Cardinal;
esp_at_signal : Cardinal
;
ss : Word;
__ssh : Word;
fpstate : pfpstate;
oldmask : Cardinal
;
cr2 : Cardinal;
end
This type is CPU dependent. Cross-platform code should not use the contents of this record.
tsiginfo = record
si_signo : LongInt;
si_errno : LongInt;
si_code
: LongInt;
_sifields : record
case LongInt of
0: (
_pad
: Array[0..(SI_PAD_SIZE)-1] of LongInt;
);
1: (
167
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
_kill : record
_pid : pid_t;
_uid : uid_t;
end;
);
2: (
_timer : record
_timer1 : DWord;
_timer2 : DWord;
end;
);
3: (
_rt : record
_pid : pid_t;
_uid
: uid_t;
_sigval : pointer;
end;
);
4: (
_sigchld
: record
_pid : pid_t;
_uid : uid_t;
_status :
LongInt;
_utime : clock_t;
_stime : clock_t;
end
;
);
5: (
_sigfault : record
_addr : pointer;
end
;
);
6: (
_sigpoll : record
_band : LongInt;
_fd
: LongInt;
end;
);
end;
end
This type describes the signal that occurred.
tsignalhandler = signalhandler_t
Alias for signalhandler_t (162) type.
tsigrestorerhandler = sigrestorerhandler_t
168
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
Alias for sigrestorerhandler_t (162) type.
tsigset = sigset_t
Alias for SigSet (162) type.
TSize = UnixType.TSize
Alias for size_t (162) type
TSocklen = UnixType.TSocklen
Alias for socklen_t (162) type.
TsSize = UnixType.TsSize
Alias for ssize_t (163) type
TStat = Stat
Alias for Stat (164) type.
tstatfs = UnixType.TStatFs
Record describing a file system in the unix.fpstatfs (128) call.
TTime = UnixType.TTime
Alias for TTime (169) type.
Ttimespec = UnixType.Ttimespec
Alias for TimeSpec (165) type.
TTimeVal = UnixType.TTimeVal
Alias for timeval (165) type.
TTimeZone = timezone
Alias for TimeZone (165) record.
TTms = tms
Alias for Tms (166) record type.
TUcontext = record
uc_flags : Cardinal;
uc_link : Pucontext;
uc_stack : tsigaltstack;
uc_mcontext : TSigContext;
uc_sigmask
: tsigset;
end
169
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
This structure is used to describe the user context in a program or thread. It is not used in this unit,
but is provided for completeness.
TUid = UnixType.TUid
Alias for uid_t (170) type.
TUtimBuf = UTimBuf
Alias for UtimBuf (170) type.
TUtsName = UtsName
Alias for UtsName (170) type.
uid_t = UnixType.uid_t
User ID type
UTimBuf = record
actime : time_t;
modtime : time_t;
end
Record used in fpUtime (220) to set file access and modification times.
UtsName = record
Sysname : Array[0..UTSNAME_LENGTH-1] of Char;
Nodename : Array[0..UTSNAME_NODENAME_LENGTH-1] of Char;
Release
: Array[0..UTSNAME_LENGTH-1] of Char;
Version : Array[0..UTSNAME_LENGTH
-1] of Char;
Machine : Array[0..UTSNAME_LENGTH-1] of Char;
Domain
: Array[0..UTSNAME_DOMAIN_LENGTH-1] of Charplatform;
end
The elements of this record are null-terminated C style strings, you cannot access them directly. Note
that the Domain field is a GNU extension, and may not be available on all platforms.
1.4 Procedures and functions
1.4.1 CreateShellArgV
Synopsis: Create a null-terminated array of strings from a command-line string
Declaration: function CreateShellArgV(const prog: string) : PPChar
function CreateShellArgV(const prog: Ansistring) : PPChar
Visibility: default
170
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
Description: CreateShellArgV creates a command-line string for executing a shell command using ’sh -c’.
The result is a null-terminated array of null-terminated strings suitable for use in fpExecv (177) and
friends.
Errors: If no more memory is available, a heap error may occur.
See also: fpExecv (177), FreeShellArgV (223)
1.4.2 FpAccess
Synopsis: Check file access
Declaration: function FpAccess(pathname: PChar; aMode: cint) : cint
function FpAccess(const pathname: RawByteString; aMode: cint) : cint
Visibility: default
Description: FpAccess tests user’s access rights on the specified file. Mode is a mask existing of one or more
of the following:
R_OKUser has read rights.
W_OKUser has write rights.
X_OKUser has execute rights.
F_OKFile exists.
The test is done with the real user ID, instead of the effective user ID. If the user has the requested
rights, zero is returned. If access is denied, or an error occurred, a nonzero value is returned.
Errors: Extended error information can be retrieved using fpGetErrno (185).
sys_eaccessThe requested access is denied, either to the file or one of the directories in its path.
sys_einvalMode was incorrect.
sys_enoentA directory component in Path doesn’t exist or is a dangling symbolic link.
sys_enotdirA directory component in Path is not a directory.
sys_enomemInsufficient kernel memory.
sys_eloopPath has a circular symbolic link.
See also: FpChown (174), FpChmod (173)
Listing: ./bunixex/ex26.pp
Program Example26 ;
{ Program t o demonstrate t h e Access f u n c t i o n . }
Uses BaseUnix ;
begin
i f fpAccess ( ’ / e t c / passwd ’ ,W_OK) = 0 then
begin
W r i t e l n ( ’ B e t t e r check your system . ’ ) ;
W r i t e l n ( ’ I can w r i t e t o t h e / e t c / passwd f i l e ! ’ ) ;
end ;
end .
171
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
1.4.3 FpAlarm
Synopsis: Schedule an alarm signal to be delivered
Declaration: function FpAlarm(seconds: cuint) : cuint
Visibility: default
Description: FpAlarm schedules an alarm signal to be delivered to your process in Seconds seconds. When
Seconds seconds have elapsed, the system will send a SIGALRM signal to the current process. If
Seconds is zero, then no new alarm will be set. Whatever the value of Seconds, any previous
alarm is cancelled.
The function returns the number of seconds till the previously scheduled alarm was due to be deliv-
ered, or zero if there was none. A negative value indicates an error.
See also: fpSigAction (209), fpPause (199)
Listing: ./bunixex/ex59.pp
Program Example59 ;
{ Program t o demonstrate t h e Alarm f u n c t i o n . }
Uses BaseUnix ;
Procedure AlarmHandler ( Sig : c i n t ) ; cdecl ;
begin
W r i t e l n ( ’ Got t o alarm h a n d l e r ’ ) ;
end ;
begin
W r i t e l n ( ’ S e t t i n g alarm h a n d l e r ’ ) ;
f p S i g n a l (SIGALRM, S i g n a l H a n d l e r ( @AlarmHandler ) ) ;
W r i t e l n ( ’ Scheduling Alarm i n 1 0 seconds ’ ) ;
fpAlarm ( 1 0 ) ;
W r i t e l n ( ’ Pausing ’ ) ;
fpPause ;
W r i t e l n ( ’ Pause r e t u r n e d ’ ) ;
end .
1.4.4 FpChdir
Synopsis: Change current working directory.
Declaration: function FpChdir(path: PChar) : cint
function FpChdir(const path: RawByteString) : cint
Visibility: default
Description: fpChDir sets the current working directory to Path.
It returns zero if the call was succesful, -1 on error.
Note: There exist a portable alterative to fpChDir: system.chdir. Please use fpChDir only if you are
writing Unix specific code. System.chdir will work on all operating systems.
Errors: Extended error information can be retrieved using fpGetErrno (185).
See also: fpGetCwd (183)
172
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
1.4.5 FpChmod
Synopsis: Change file permission bits
Declaration: function FpChmod(path: PChar; Mode: TMode) : cint
function FpChmod(const path: RawByteString; Mode: TMode) : cint
Visibility: default
Description: fpChmod sets the Mode bits of the file in Path to Mode. Mode can be specified by ’or’-ing the
following values:
S_ISUIDSet user ID on execution.
S_ISGIDSet Group ID on execution.
S_ISVTXSet sticky bit.
S_IRUSRRead by owner.
S_IWUSRWrite by owner.
S_IXUSRExecute by owner.
S_IRGRPRead by group.
S_IWGRPWrite by group.
S_IXGRPExecute by group.
S_IROTHRead by others.
S_IWOTHWrite by others.
S_IXOTHExecute by others.
S_IRWXORead, write, execute by others.
S_IRWXGRead, write, execute by groups.
S_IRWXURead, write, execute by user.
If the function is successful, zero is returned. A nonzero return value indicates an error.
Errors: The following error codes are returned:
sys_epermThe effective UID doesn’t match the ownership of the file, and is not zero. Owner or
group were not specified correctly.
sys_eaccessOne of the directories in Path has no search (=execute) permission.
sys_enoentA directory entry in Path does not exist or is a symbolic link pointing to a non-existent
directory.
sys_enomemInsufficient kernel memory.
sys_erofsThe file is on a read-only filesystem.
sys_eloopPath has a reference to a circular symbolic link, i.e. a symbolic link, whose expansion
points to itself.
See also: fpChown (174), fpAccess (171)
Listing: ./bunixex/ex23.pp
173
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
Program Example23 ;
{ Program t o demonstrate t h e Chmod f u n c t i o n . }
Uses BaseUnix , Unix ;
Var F : Text ;
begin
{ Create a f i l e }
Assign ( f , ’ t e s t e x 2 1 ’ ) ;
Rewrite ( F ) ;
W r i t e l n ( f , ’ # ! / b i n / sh ’ ) ;
W r i t e l n ( f , ’ echo Some t e x t f o r t h i s f i l e ’ ) ;
Close ( F ) ;
fpChmod ( ’ t e s t e x 2 1 ’ , & 7 7 7 ) ;
{ F i l e i s now e x e c u t a b l e }
fpexecl ( ’ . / testex21 ’ , [ ] ) ;
end .
1.4.6 FpChown
Synopsis: Change owner of file
Declaration: function FpChown(path: PChar; owner: TUid; group: TGid) : cint
function FpChown(const path: RawByteString; owner: TUid; group: TGid)
: cint
Visibility: default
Description: fpChown sets the User ID and Group ID of the file in Path to Owner,Group.
The function returns zero if the call was succesfull, a nonzero return value indicates an error.
Errors: The following error codes are returned:
sys_epermThe effective UID doesn’t match the ownership of the file, and is not zero. Owner or
group were not specified correctly.
sys_eaccessOne of the directories in Path has no search (=execute) permission.
sys_enoentA directory entry in Path does not exist or is a symbolic link pointing to a non-existent
directory.
sys_enomemInsufficient kernel memory.
sys_erofsThe file is on a read-only filesystem.
sys_eloopPath has a reference to a circular symbolic link, i.e. a symbolic link, whose expansion
points to itself.
See also: fpChmod (173), fpAccess (171)
Listing: ./bunixex/ex24.pp
Program Example24 ;
{ Program t o demonstrate t h e Chown f u n c t i o n . }
Uses BaseUnix ;
174
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
Var UID : TUid ;
GID : TGid ;
F : Text ;
begin
W r i t e l n ( ’ T h i s w i l l o n l y work i f you are r o o t . ’ ) ;
Write ( ’ E n t e r a UID : ’ ) ; readln ( UID ) ;
Write ( ’ E n t e r a GID : ’ ) ; readln ( GID ) ;
Assign ( f , ’ t e s t . t x t ’ ) ;
Rewrite ( f ) ;
W r i t e l n ( f , ’ The owner o f t h i s f i l e should become : ’ ) ;
W r i t e l n ( f , ’ UID : ’ , UID ) ;
W r i t e l n ( f , ’ GID : ’ , GID ) ;
Close ( F ) ;
i f fpChown ( ’ t e s t . t x t ’ , UID , GID) < >0 then
i f f p g e t e r r n o =ESysEPERM then
W r i t e l n ( ’ You are n o t r o o t ! ’ )
else
W r i t e l n ( ’Chmod f a i l e d w i t h e x i t code : ’ , f p g e t e r r n o )
else
W r i t e l n ( ’ Changed owner s u c c e s s f u l l y ! ’ ) ;
end .
1.4.7 FpClose
Synopsis: Close file descriptor
Declaration: function FpClose(fd: cint) : cint
Visibility: default
Description: FpClose closes a file with file descriptor Fd. The function returns zero if the file was closed
successfully, a nonzero return value indicates an error.
For an example, see FpOpen (197).
Errors: Extended error information can be retrieved using fpGetErrno (185).
See also: FpOpen (197), FpRead (201), FpWrite (222), FpFTruncate (183), FpLSeek (191)
1.4.8 FpClosedir
Synopsis: Close directory file descriptor
Declaration: function FpClosedir(var dirp: Dir) : cint
Visibility: default
Description: FpCloseDir closes the directory pointed to by dirp. It returns zero if the directory was closed
succesfully, -1 otherwise.
For an example, see fpOpenDir (198).
Errors: Extended error information can be retrieved using fpGetErrno (185).
See also: FpOpenDir (198), FpReadDir (202)
175
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
1.4.9 FpDup
Synopsis: Duplicate a file handle
Declaration: function FpDup(fildes: cint) : cint
function FpDup(var oldfile: text; var newfile: text) : cint
function FpDup(var oldfile: File; var newfile: File) : cint
Visibility: default
Description: FpDup returns a file descriptor that is a duplicate of the file descriptor fildes.
The second and third forms make NewFile an exact copy of OldFile, after having flushed the
buffer of OldFile in case it is a Text file or untyped file. Due to the buffering mechanism of Pascal,
these calls do not have the same functionality as the dup call in C. The internal Pascal buffers are not
the same after this call, but when the buffers are flushed (e.g. after output), the output is sent to the
same file. Doing an lseek will, however, work as in C, i.e. doing a lseek will change the fileposition
in both files.
The function returns a negative value in case of an error, a positive value is a file handle, and indicates
succes.
Errors: A negative value can be one of the following error codes:
sys_ebadfOldFile hasn’t been assigned.
sys_emfileMaximum number of open files for the process is reached.
See also: fpDup2 (176)
Listing: ./bunixex/ex31.pp
program Example31 ;
{ Program t o demonstrate t h e Dup f u n c t i o n . }
uses baseunix ;
var f : t e x t ;
begin
i f fpdup ( o u t p u t , f )= −1 then
W r i t e l n ( ’ Dup F a i l e d ! ’ ) ;
writeln ( ’ This i s w r i t t e n to stdout . ’ ) ;
w r i t e l n ( f , ’ T h i s i s w r i t t e n t o t h e dup f i l e , and f l u s h e d ’ ) ; f l u s h ( f ) ;
writeln
end .
1.4.10 FpDup2
Synopsis: Duplicate one filehandle to another
Declaration: function FpDup2(fildes: cint; fildes2: cint) : cint
function FpDup2(var oldfile: text; var newfile: text) : cint
function FpDup2(var oldfile: File; var newfile: File) : cint
Visibility: default
176
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
Description: Makes fildes2 or NewFile an exact copy of fildes or OldFile, after having flushed the
buffer of OldFile in the case of text or untyped files.
After a call to fdup2, the 2 file descriptors point to the same physical device (a file, socket, or a
terminal).
NewFile can be an assigned file. If newfile or fildes was open, it is closed first. Due to the
buffering mechanism of Pascal, this has not the same functionality as the dup2 call in C. The internal
Pascal buffers are not the same after this call, but when the buffers are flushed (e.g. after output), the
output is sent to the same file. Doing an lseek will, however, work as in C, i.e. doing a lseek will
change the fileposition in both files.
The function returns the new file descriptor number, on error -1 is returned, and the error can be
retrieved with fpgeterrno (185)
Errors: In case of error, the following error codes can be reported:
sys_ebadfOldFile (or fildes) hasn’t been assigned.
sys_emfileMaximum number of open files for the process is reached.
See also: fpDup (176)
Listing: ./bunixex/ex32.pp
program Example32 ;
{ Program t o demonstrate t h e FpDup2 f u n c t i o n . }
uses BaseUnix ;
var f : t e x t ;
i : longint ;
begin
Assign ( f , ’ t e x t . t x t ’ ) ;
Rewrite ( F ) ;
For i : = 1 to 1 0 do w r i t e l n ( F , ’ L i n e : ’ , i ) ;
i f fpdup2 ( o u t p u t , f )= −1 then
W r i t e l n ( ’ Dup2 F a i l e d ! ’ ) ;
writeln ( ’ This i s w r i t t e n to stdout . ’ ) ;
w r i t e l n ( f , ’ T h i s i s w r i t t e n t o t h e dup f i l e , and f l u s h e d ’ ) ;
flush ( f ) ;
writeln ;
{ Remove f i l e . Comment t h i s i f you want t o check f l u s h i n g . }
fpUnlink ( ’ text . t x t ’ ) ;
end .
1.4.11 FpExecv
Synopsis: Execute process
Declaration: function FpExecv(path: PChar; argv: PPChar) : cint
function FpExecv(const path: RawByteString; argv: PPChar) : cint
Visibility: default
177
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
Description: Replaces the currently running program with the program, specified in path. It gives the program
the options in argvp. This is a pointer to an array of pointers to null-terminated strings. The last
pointer in this array should be nil. The current environment is passed to the program. On success,
execv does not return.
Errors: On error, -1 is returned. Extended error information can be retrieved with fpGetErrNo (185)
sys_eaccesFile is not a regular file, or has no execute permission. A compononent of the path has no
search permission.
sys_epermThe file system is mounted \textit{noexec}.
sys_e2bigArgument list too big.
sys_enoexecThe magic number in the file is incorrect.
sys_enoentThe file does not exist.
sys_enomemNot enough memory for kernel.
sys_enotdirA component of the path is not a directory.
sys_eloopThe path contains a circular reference (via symlinks).
See also: fpExecve (178), fpFork (182)
Listing: ./bunixex/ex8.pp
Program Example8 ;
{ Program t o demonstrate t h e Execv f u n c t i o n . }
Uses Unix , s t r i n g s ;
Const Arg0 : PChar = ’ / b i n / l s ’ ;
Arg1 : Pchar = ’− l ’ ;
Var PP : PPchar ;
begin
GetMem ( PP, 3 ∗ SizeOf ( Pchar ) ) ;
PP [ 0 ] : = Arg0 ;
PP [ 1 ] : = Arg1 ;
PP [ 3 ] : = N i l ;
{ Execute ’ / b i n / l s − l ’ , w i t h c u r r e n t environment }
fpExecv ( ’ / b i n / l s ’ , pp ) ;
end .
1.4.12 FpExecve
Synopsis: Execute process using environment
Declaration: function FpExecve(path: PChar; argv: PPChar; envp: PPChar) : cint
function FpExecve(const path: RawByteString; argv: PPChar; envp: PPChar)
: cint
Visibility: default
178
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
Description: Replaces the currently running program with the program, specified in path. It gives the program
the options in argv, and the environment in envp. They are pointers to an array of pointers to
null-terminated strings. The last pointer in this array should be nil. On success, execve does not
return.
Errors: Extended error information can be retrieved with fpGetErrno (185), and includes the following:
sys_eaccesFile is not a regular file, or has no execute permission. A compononent of the path has no
search permission.
sys_epermThe file system is mounted \textit{noexec}.
sys_e2bigArgument list too big.
sys_enoexecThe magic number in the file is incorrect.
sys_enoentThe file does not exist.
sys_enomemNot enough memory for kernel.
sys_enotdirA component of the path is not a directory.
sys_eloopThe path contains a circular reference (via symlinks).
See also: fpExecv (177), fpFork (182)
Listing: ./bunixex/ex7.pp
Program Example7 ;
{ Program t o demonstrate t h e Execve f u n c t i o n . }
Uses BaseUnix , s t r i n g s ;
Const Arg0 : PChar = ’ / b i n / l s ’ ;
Arg1 : Pchar = ’− l ’ ;
Var PP : PPchar ;
begin
GetMem ( PP, 3 ∗ SizeOf ( Pchar ) ) ;
PP [ 0 ] : = Arg0 ;
PP [ 1 ] : = Arg1 ;
PP [ 3 ] : = N i l ;
{ Execute ’ / b i n / l s − l ’ , w i t h c u r r e n t environment }
{ Envp i s d e f i n e d i n system . i n c }
fpExecVe ( ’ / b i n / l s ’ , pp , envp ) ;
end .
1.4.13 FpExit
Synopsis: Exit the current process
Declaration: procedure FpExit(Status: cint)
Visibility: default
Description: FpExit exits the currently running process, and report Status as the exit status.
Remark: If this call is executed, the normal unit finalization code will not be executed. This may lead to
unexpected errors and stray files on your system. It is therefore recommended to use the Halt call
instead.
179
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
Errors: None.
See also: FpFork (182), FpExecve (178)
1.4.14 FpFcntl
Synopsis: File control operations.
Declaration: function FpFcntl(fildes: cint; cmd: cint) : cint
function FpFcntl(fildes: cint; cmd: cint; arg: cint) : cint
function FpFcntl(fildes: cint; cmd: cint; var arg: FLock) : cint
Visibility: default
Description: Read/set a file’s attributes. Fildes a valid file descriptor. Cmd speciefies what to do, and is one of
the following:
F_GetFdRead the close_on_exec flag. If the low-order bit is 0, then the file will remain open across
execve calls.
F_GetFlRead the descriptor’s flags.
F_GetOwnGet the Process ID of the owner of a socket.
F_SetFdSet the close_on_exec flag of fildes. (only the least siginificant bit is used).
F_GetLkReturn the flock record that prevents this process from obtaining the lock, or set the
l_type field of the lock of there is no obstruction. Arg is the flock record.
F_SetLkSet the lock or clear it (depending on l_type in the flock structure). if the lock is held
by another process, an error occurs.
F_GetLkwSame as for F_Setlk, but wait until the lock is released.
F_SetOwnSet the Process or process group that owns a socket.
The function returns 0 if successful, -1 otherwise.
Errors: On error, -1 is returned. Use fpGetErrno (185) for extended error information.
sys_ebadfFd has a bad file descriptor.
sys_eagain or sys_eaccessFor \textbf{F_SetLk}, if the lock is held by another process.
1.4.15 fpfdfillset
Synopsis: Set all filedescriptors in the set.
Declaration: function fpfdfillset(var nset: TFDSet) : cint
Visibility: default
Description: fpfdfillset sets all filedescriptors in nset.
See also: FpSelect (205), FpFD_ZERO (181), FpFD_IsSet (181), FpFD_Clr (181), FpFD_Set (181)
180
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
1.4.16 fpFD_CLR
Synopsis: Clears a filedescriptor in a set
Declaration: function fpFD_CLR(fdno: cint; var nset: TFDSet) : cint
Visibility: default
Description: FpFD_Clr clears file descriptor fdno in filedescriptor set nset.
For an example, see FpSelect (205).
Errors: None.
See also: FpSelect (205), FpFD_ZERO (181), FpFD_Set (181), FpFD_IsSet (181)
1.4.17 fpFD_ISSET
Synopsis: Check whether a filedescriptor is set
Declaration: function fpFD_ISSET(fdno: cint; const nset: TFDSet) : cint
Visibility: default
Description: FpFD_Set Checks whether file descriptor fdNo in filedescriptor set fds is set. It returns zero if
the descriptor is not set, 1 if it is set. If the number of the filedescriptor it wrong, -1 is returned.
For an example, see FpSelect (205).
Errors: If an invald file descriptor number is passed, -1 is returned.
See also: FpSelect (205), FpFD_ZERO (181), FpFD_Clr (181), FpFD_Set (181)
1.4.18 fpFD_SET
Synopsis: Set a filedescriptor in a set
Declaration: function fpFD_SET(fdno: cint; var nset: TFDSet) : cint
Visibility: default
Description: FpFD_Set sets file descriptor fdno in filedescriptor set nset.
For an example, see FpSelect (205).
Errors: None.
See also: FpSelect (205), FpFD_ZERO (181), FpFD_Clr (181), FpFD_IsSet (181)
1.4.19 fpFD_ZERO
Synopsis: Clear all file descriptors in set
Declaration: function fpFD_ZERO(out nset: TFDSet) : cint
Visibility: default
Description: FpFD_ZERO clears all the filedescriptors in the file descriptor set nset.
For an example, see FpSelect (205).
Errors: None.
See also: FpSelect (205), FpFD_Clr (181), FpFD_Set (181), FpFD_IsSet (181)
181
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
1.4.20 FpFork
Synopsis: Create child process
Declaration: function FpFork : TPid
Visibility: default
Description: FpFork creates a child process which is a copy of the parent process. FpFork returns the process
ID in the parent process, and zero in the child’s process. (you can get the parent’s PID with fpGetPPid
(187)).
Errors: On error, -1 is returned to the parent, and no child is created.
sys_eagainNot enough memory to create child process.
See also: fpExecve (178), #rtl.linux.Clone (929)
1.4.21 FPFStat
Synopsis: Retrieve file information about a file descriptor.
Declaration: function FpFStat(fd: cint; var sb: Stat) : cint
function FPFStat(var F: Text; var Info: Stat) : Boolean
function FPFStat(var F: File; var Info: Stat) : Boolean
Visibility: default
Description: FpFStat gets information about the file specified in one of the following:
Fda valid file descriptor.
Fan opened text file or untyped file.
and stores it in Info, which is of type stat (164). The function returns zero if the call was succesfull,
a nonzero return value indicates failure.
Errors: Extended error information can be retrieved using fpGetErrno (185).
sys_enoentPath does not exist.
See also: FpStat (214), FpLStat (191)
Listing: ./bunixex/ex28.pp
program example28 ;
{ Program t o demonstrate t h e F S t a t f u n c t i o n . }
uses BaseUnix ;
var f : t e x t ;
i : byte ;
info : stat ;
begin
{ Make a f i l e }
assign ( f , ’ t e s t . f i l ’ ) ;
rewrite ( f ) ;
f o r i : = 1 to 1 0 do w r i t e l n ( f , ’ T e s t l i n e # ’ , i ) ;
182
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
close ( f ) ;
{ Do t h e c a l l on made f i l e . }
i f f p s t a t ( ’ t e s t . f i l ’ , i n f o ) < >0 then
begin
w r i t e l n ( ’ F s t a t f a i l e d . Errno : ’ , f p g e t e r r n o ) ;
halt ( 1 ) ;
end ;
writeln ;
w r i t e l n ( ’ R e s u l t o f f s t a t on f i l e ’ ’ t e s t . f i l ’ ’ . ’ ) ;
w r i t e l n ( ’ Inode : ’ , info . st_ino ) ;
w r i t e l n ( ’ Mode : ’ , i n f o . st_mode ) ;
writeln ( ’ nlink : ’ , info . st_nlink );
writeln ( ’ uid : ’ , info . st_uid ) ;
writeln ( ’ gid : ’ , info . st_gid ) ;
w r i t e l n ( ’ rdev : ’ , i n f o . st_rdev ) ;
w r i t e l n ( ’ Size : ’ , info . st_size ) ;
writeln ( ’ Blksize : ’ , info . st_blksize ) ;
w r i t e l n ( ’ Blocks : ’ , info . st_blocks ) ;
w r i t e l n ( ’ atime : ’ , i n f o . st_atime ) ;
w r i t e l n ( ’ mtime : ’ , i n f o . st_mtime ) ;
writeln ( ’ ctime : ’ , i n f o . st_ctime ) ;
{ Remove f i l e }
erase ( f ) ;
end .
1.4.22 FpFtruncate
Synopsis: Truncate file on certain size.
Declaration: function FpFtruncate(fd: cint; flength: TOff) : cint
Visibility: default
Description: FpFTruncate sets the length of a file in fd on flength bytes, where flength must be less
than or equal to the current length of the file in fd.
The function returns zero if the call was successful, a nonzero return value indicates that an error
occurred.
Errors: Extended error information can be retrieved using fpGetErrno (185).
See also: FpOpen (197), FpClose (175), FpRead (201), FpWrite (222), FpLSeek (191)
1.4.23 FpGetcwd
Synopsis: Retrieve the current working directory.
Declaration: function FpGetcwd(path: PChar; siz: TSize) : PChar
function FpGetcwd : RawByteString
Visibility: default
Description: fpgetCWD returns the current working directory of the running process. It is returned in Path,
which points to a memory location of at least siz bytes.
If the function is succesful, a pointer to Path is returned, or a string with the result. On error Nil
or an empty string are returned.
183
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
Errors: On error Nil or an empty string are returned.
See also: FpGetPID (186), FpGetUID (188)
1.4.24 FpGetegid
Synopsis: Return effective group ID
Declaration: function FpGetegid : TGid
Visibility: default
Description: FpGetegid returns the effective group ID of the currently running process.
Errors: None.
See also: FpGetGid (185), FpGetUid (188), FpGetEUid (185), FpGetPid (186), FpGetPPid (187), fpSetUID
(208), FpSetGid (207)
Listing: ./bunixex/ex18.pp
Program Example18 ;
{ Program t o demonstrate t h e GetGid and GetEGid f u n c t i o n s . }
Uses BaseUnix ;
begin
w r i t e l n ( ’ Group I d = ’ , f p g e t g i d , ’ E f f e c t i v e group I d = ’ , f p g e t e g i d ) ;
end .
1.4.25 FpGetEnv
Synopsis: Return value of environment variable.
Declaration: function FpGetEnv(name: PChar) : PChar
function FpGetEnv(name: string) : PChar
Visibility: default
Description: FPGetEnv returns the value of the environment variable in Name. If the variable is not defined, nil
is returned. The value of the environment variable may be the empty string. A PChar is returned to
accomodate for strings longer than 255 bytes, TERMCAP and LS_COLORS, for instance.
Errors: None.
Listing: ./bunixex/ex41.pp
Program Example41 ;
{ Program t o demonstrate t h e GetEnv f u n c t i o n . }
Uses BaseUnix ;
begin
W r i t e l n ( ’ Path i s : ’ , fpGetenv ( ’PATH ’ ) ) ;
end .
184
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
1.4.26 fpgeterrno
Synopsis: Retrieve extended error information.
Declaration: function fpgeterrno : LongInt
Visibility: default
Description: fpgeterrno returns extended information on the latest error. It is set by all functions that com-
municate with the kernel or C library.
Errors: None.
See also: fpseterrno (207)
1.4.27 FpGeteuid
Synopsis: Return effective user ID
Declaration: function FpGeteuid : TUid
Visibility: default
Description: FpGeteuid returns the effective user ID of the currently running process.
Errors: None.
See also: FpGetUid (188), FpGetGid (185), FpGetEGid (184), FpGetPid (186), FpGetPPid (187), fpSetUID
(208), FpSetGid (207)
Listing: ./bunixex/ex17.pp
Program Example17 ;
{ Program t o demonstrate t h e GetUid and GetEUid f u n c t i o n s . }
Uses BaseUnix ;
begin
w r i t e l n ( ’ User I d = ’ , f p g e t u i d , ’ E f f e c t i v e user I d = ’ , f p g e t e u i d ) ;
end .
1.4.28 FpGetgid
Synopsis: Return real group ID
Declaration: function FpGetgid : TGid
Visibility: default
Description: FpGetgid returns the real group ID of the currently running process.
Errors: None.
See also: FpGetEGid (184), FpGetUid (188), FpGetEUid (185), FpGetPid (186), FpGetPPid (187), fpSetUID
(208), FpSetGid (207)
Listing: ./bunixex/ex18.pp
185
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
Program Example18 ;
{ Program t o demonstrate t h e GetGid and GetEGid f u n c t i o n s . }
Uses BaseUnix ;
begin
w r i t e l n ( ’ Group I d = ’ , f p g e t g i d , ’ E f f e c t i v e group I d = ’ , f p g e t e g i d ) ;
end .
1.4.29 FpGetgroups
Synopsis: Get the list of supplementary groups.
Declaration: function FpGetgroups(gidsetsize: cint; var grouplist: TGrpArr) : cint
Visibility: default
Description: FpGetgroups returns up to gidsetsize groups in GroupList
If the function is successful, then number of groups that were stored is returned. On error, -1 is
returned.
Errors: On error, -1 is returned. Extended error information can be retrieved with fpGetErrNo (185)
See also: FpGetpgrp (186), FpGetGID (185), FpGetEGID (184)
1.4.30 FpGetpgrp
Synopsis: Get process group ID
Declaration: function FpGetpgrp : TPid
Visibility: default
Description: FpGetpgrp returns the process group ID of the current process.
Errors: None.
See also: fpGetPID (186), fpGetPPID (187), FpGetGID (185), FpGetUID (188)
1.4.31 FpGetpid
Synopsis: Return current process ID
Declaration: function FpGetpid : TPid
Visibility: default
Description: FpGetpid returns the process ID of the currently running process.
Note: There exist a portable alterative to fpGetpid: system.GetProcessID. Please use fpGetpid only
if you are writing Unix specific code. System.GetProcessID will work on all operating systems.
Errors: None.
See also: FpGetPPid (187)
186
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
Listing: ./bunixex/ex16.pp
Program Example16 ;
{ Program t o demonstrate t h e GetPid , GetPPid f u n c t i o n . }
Uses BaseUnix ;
begin
W r i t e l n ( ’ Process I d = ’ , f p g e t p i d , ’ Parent process I d = ’ , f p g e t p p i d ) ;
end .
1.4.32 FpGetppid
Synopsis: Return parent process ID
Declaration: function FpGetppid : TPid
Visibility: default
Description: FpGetppid returns the Process ID of the parent process.
Errors: None.
See also: FpGetPid (186)
Listing: ./bunixex/ex16.pp
Program Example16 ;
{ Program t o demonstrate t h e GetPid , GetPPid f u n c t i o n . }
Uses BaseUnix ;
begin
W r i t e l n ( ’ Process I d = ’ , f p g e t p i d , ’ Parent process I d = ’ , f p g e t p p i d ) ;
end .
1.4.33 fpGetPriority
Synopsis: Return process priority
Declaration: function fpGetPriority(Which: cint; Who: cint) : cint
Visibility: default
Description: GetPriority returns the priority with which a process is running. Which process(es) is determined by
the Which and Who variables. Which can be one of the pre-defined Prio_Process, Prio_PGrp,
Prio_User, in which case Who is the process ID, Process group ID or User ID, respectively.
For an example, see FpNice (196).
Errors: Error information is returned solely by the FpGetErrno (185) function: a priority can be a positive
or negative value.
sys_esrchNo process found using which and who.
sys_einvalWhich was not one of Prio_Process, Prio_Grp or Prio_User.
See also: FpSetPriority (207), FpNice (196)
187
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
1.4.34 FpGetRLimit
Synopsis: Get process resource limits
Declaration: function FpGetRLimit(resource: cint; rlim: PRLimit) : cint
Visibility: default
Description: FpGetRLimit gets the resource limits for the current process: resource determines the resource
of which the kernel should return the limits (one of the many RLIMIT_* constants). rlim should
point to a TRLimit (166) record and on success will contain the resource limits.
The function returns zero if the resource limits were correctly returned.
Errors: On error, -1 is returned and fpgeterrno (185) can be used to retrieve the error code.
See also: FpSetRLimit (208)
1.4.35 FpGetsid
Synopsis: Get current session ID
Declaration: function FpGetsid(pid: TPid) : TPid
Visibility: default
Description: FpGetsid returns the session ID of the process pid. The return value is the session ID of the
process. (it equals the PID of the session leader). The process pid must be in the same session as the
current process.
Errors: On error, -1 is returned, and extended error information can be obtained with fpGetErrno.
See also: FpGetpgrp (186), FpGetpid (186), FpGetPpid (187)
1.4.36 FpGetuid
Synopsis: Return current user ID
Declaration: function FpGetuid : TUid
Visibility: default
Description: FpGetuid returns the real user ID of the currently running process.
Errors: None.
See also: FpGetGid (185), FpGetEUid (185), FpGetEGid (184), FpGetPid (186), FpGetPPid (187), fpSetUID
(208)
Listing: ./bunixex/ex17.pp
Program Example17 ;
{ Program t o demonstrate t h e GetUid and GetEUid f u n c t i o n s . }
Uses BaseUnix ;
begin
w r i t e l n ( ’ User I d = ’ , f p g e t u i d , ’ E f f e c t i v e user I d = ’ , f p g e t e u i d ) ;
end .
188
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
1.4.37 FpIOCtl
Synopsis: General kernel IOCTL call.
Declaration: function FpIOCtl(Handle: cint; Ndx: TIOCtlRequest; Data: Pointer) : cint
Visibility: default
Description: This is a general interface to the Unix/ Linux ioctl call. It performs various operations on the
filedescriptor Handle. Ndx describes the operation to perform. Data points to data needed for
the Ndx function. The structure of this data is function-dependent, so we don’t elaborate on this
here. For more information on this, see various manual pages under Linux.
Errors: Extended error information can be retrieved using fpGetErrno (185).
Listing: ./bunixex/ex54.pp
Program Example54 ;
uses BaseUnix , Termio ;
{ Program t o demonstrate t h e I O C t l f u n c t i o n . }
var
t i o s : Termios ;
begin
{ $ i f d e f FreeBSD }
f p I O C t l ( 1 ,TIOCGETA, @tios ) ; / / these c o n s t a n t s are v e r y OS dependant .
/ / see t h e t c g e t a t t r example f o r a b e t t e r way
{ $endif }
WriteLn ( ’ I n p u t Flags : $’ , hexstr ( tios . c_iflag ,8));
WriteLn ( ’ Output Flags : $’ , hexstr ( tios . c_oflag ,8));
WriteLn ( ’ L i n e Flags : $’ , hexstr ( tios . c_lflag ,8));
WriteLn ( ’ C o n t r o l Flags : $’ , hexstr ( tios . c_cflag ,8));
end .
1.4.38 FpKill
Synopsis: Send a signal to a process
Declaration: function FpKill(pid: TPid; sig: cint) : cint
Visibility: default
Description: fpKill sends a signal Sig to a process or process group. If Pid>0 then the signal is sent to Pid,
if it equals -1, then the signal is sent to all processes except process 1. If Pid<-1 then the signal is
sent to process group -Pid.
The return value is zero, except in case three, where the return value is the number of processes to
which the signal was sent.
Errors: Extended error information can be retrieved using fpGetErrno (185):
sys_einvalAn invalid signal is sent.
sys_esrchThe Pid or process group don’t exist.
sys_epermThe effective userid of the current process doesn’t math the one of process Pid.
See also: FpSigAction (209), FpSignal (211)
189
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
1.4.39 FpLink
Synopsis: Create a hard link to a file
Declaration: function FpLink(existing: PChar; newone: PChar) : cint
function FpLink(const existing: RawByteString;
const newone: RawByteString) : cint
Visibility: default
Description: fpLink makes NewOne point to the same file als Existing. The two files then have the same
inode number. This is known as a ’hard’ link. The function returns zero if the call was succesfull,
and returns a non-zero value if the call failed.
Errors: The following error codes are returned:
sys_exdevExisting and NewOne are not on the same filesystem.
sys_epermThe filesystem containing Existing and NewOne doesn’t support linking files.
sys_eaccessWrite access for the directory containing NewOne is disallowed, or one of the directories
in Existing or NewOne has no search (=execute) permission.
sys_enoentA directory entry in Existing or NewOne does not exist or is a symbolic link pointing
to a non-existent directory.
sys_enotdirA directory entry in Existing or NewOne is nor a directory.
sys_enomemInsufficient kernel memory.
sys_erofsThe files are on a read-only filesystem.
sys_eexistNewOne already exists.
sys_emlinkExisting has reached maximal link count.
sys_eloopexisting or NewOne has a reference to a circular symbolic link, i.e. a symbolic link,
whose expansion points to itself.
sys_enospcThe device containing NewOne has no room for another entry.
sys_epermExisting points to . or .. of a directory.
See also: fpSymLink (215), fpUnLink (220)
Listing: ./bunixex/ex21.pp
Program Example21 ;
{ Program t o demonstrate t h e L i n k and UnLink f u n c t i o n s . }
Uses BaseUnix ;
Var F : Text ;
S : String ;
begin
Assign ( F , ’ t e s t . t x t ’ ) ;
Rewrite ( F ) ;
Writeln ( F , ’ This i s w r i t t e n to t e s t . t x t ’ ) ;
Close ( f ) ;
{ new . t x t and t e s t . t x t are now t h e same f i l e }
i f f p L i n k ( ’ t e s t . t x t ’ , ’ new . t x t ’ ) < >0 then
w r i t e l n ( ’ E r r o r when l i n k i n g ! ’ ) ;
{ Removing t e s t . t x t s t i l l l e a v e s new . t x t }
I f f p U n l i n k ( ’ t e s t . t x t ’ ) < >0 then
190
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
W r i t e l n ( ’ E r r o r when u n l i n k i n g ! ’ ) ;
Assign ( f , ’ new . t x t ’ ) ;
Reset ( F ) ;
While not EOF( f ) do
begin
Readln ( F , S ) ;
Writeln ( ’ > ’ , s ) ;
end ;
Close ( f ) ;
{ Remove new . t x t a l s o }
I f not FPUnlink ( ’ new . t x t ’ ) < >0 then
W r i t e l n ( ’ E r r o r when u n l i n k i n g ! ’ ) ;
end .
1.4.40 FpLseek
Synopsis: Set file pointer position.
Declaration: function FpLseek(fd: cint; offset: TOff; whence: cint) : TOff
Visibility: default
Description: FpLSeek sets the current fileposition of file fd to Offset, starting from Whence, which can be
one of the following:
Seek_SetOffset is the absolute position in the file.
Seek_CurOffset is relative to the current position.
Seek_endOffset is relative to the end of the file.
The function returns the new fileposition, or -1 of an error occurred.
For an example, see FpOpen (197).
Errors: Extended error information can be retrieved using fpGetErrno (185).
See also: FpOpen (197), FpWrite (222), FpClose (175), FpRead (201), FpFTruncate (183)
1.4.41 fpLstat
Synopsis: Return information about symbolic link. Do not follow the link
Declaration: function fpLstat(path: PChar; Info: PStat) : cint
function fpLstat(const path: RawByteString; Info: PStat) : cint
function fpLstat(path: PChar; var Info: Stat) : cint
function fpLstat(const Filename: RawByteString; var Info: Stat) : cint
Visibility: default
Description: FpLstat gets information about the link specified in Path (or FileName, and stores it in Info,
which points to a record of type TStat. Contrary to FpFstat (182), it stores information about the
link, not about the file the link points to. The function returns zero if the call was succesful, a nonzero
return value indicates failure. failed.
Errors: Extended error information is returned by the FpGetErrno (185) function.
sys_enoentPath does not exist.
191
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
See also: FpFStat (182), #rtl.unixtype.TStatFS (1979)
Listing: ./unixex/ex29.pp
program example29 ;
{ Program t o demonstrate t h e L S t a t f u n c t i o n . }
uses BaseUnix , Unix ;
var f : t e x t ;
i : byte ;
info : stat ;
begin
{ Make a f i l e }
assign ( f , ’ t e s t . f i l ’ ) ;
rewrite ( f ) ;
f o r i : = 1 to 1 0 do w r i t e l n ( f , ’ T e s t l i n e # ’ , i ) ;
close ( f ) ;
{ Do t h e c a l l on made f i l e . }
i f f p s t a t ( ’ t e s t . f i l ’ , i n f o ) < >0 then
begin
w r i t e l n ( ’ F s t a t f a i l e d . Errno : ’ , f p g e t e r r n o ) ;
halt ( 1 ) ;
end ;
writeln ;
w r i t e l n ( ’ R e s u l t o f s t a t on f i l e ’ ’ t e s t . f i l ’ ’ . ’ ) ;
w r i t e l n ( ’ Inode : ’ , info . st_ino ) ;
w r i t e l n ( ’ Mode : ’ , i n f o . st_mode ) ;
writeln ( ’ nlink : ’ , info . st_nlink );
writeln ( ’ uid : ’ , info . st_uid ) ;
writeln ( ’ gid : ’ , info . st_gid ) ;
w r i t e l n ( ’ rdev : ’ , i n f o . st_rdev ) ;
w r i t e l n ( ’ Size : ’ , info . st_size ) ;
writeln ( ’ Blksize : ’ , info . st_blksize ) ;
w r i t e l n ( ’ Blocks : ’ , info . st_blocks ) ;
w r i t e l n ( ’ atime : ’ , i n f o . st_atime ) ;
w r i t e l n ( ’ mtime : ’ , i n f o . st_mtime ) ;
writeln ( ’ ctime : ’ , i n f o . st_ctime ) ;
If fpSymLink ( ’ t e s t . f i l ’ , ’ t e s t . l n k ’ ) < >0 then
w r i t e l n ( ’ L i n k f a i l e d ! Errno : ’ , f p g e t e r r n o ) ;
if f p l s t a t ( ’ t e s t . l n k ’ , @info ) < >0 then
begin
w r i t e l n ( ’ L S t a t f a i l e d . Errno : ’ , f p g e t e r r n o ) ;
halt ( 1 ) ;
end ;
writeln ;
w r i t e l n ( ’ R e s u l t o f f s t a t on f i l e ’ ’ t e s t . l n k ’ ’ . ’ ) ;
w r i t e l n ( ’ Inode : ’ , info . st_ino ) ;
w r i t e l n ( ’ Mode : ’ , i n f o . st_mode ) ;
writeln ( ’ nlink : ’ , info . st_nlink );
writeln ( ’ uid : ’ , info . st_uid ) ;
writeln ( ’ gid : ’ , info . st_gid ) ;
w r i t e l n ( ’ rdev : ’ , i n f o . st_rdev ) ;
w r i t e l n ( ’ Size : ’ , info . st_size ) ;
writeln ( ’ Blksize : ’ , info . st_blksize ) ;
192
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
w r i t e l n ( ’ Blocks : ’ , info . st_blocks ) ;
w r i t e l n ( ’ atime : ’ , info . st_atime ) ;
w r i t e l n ( ’ mtime : ’ , info . st_mtime ) ;
writeln ( ’ ctime : ’ , info . st_ctime ) ;
{ Remove f i l e and l i n k }
erase ( f ) ;
fpunlink ( ’ test . lnk ’ ) ;
end .
1.4.42 FpMkdir
Synopsis: Create a new directory
Declaration: function FpMkdir(path: PChar; Mode: TMode) : cint
function FpMkdir(const path: RawByteString; Mode: TMode) : cint
Visibility: default
Description: FpMkDir creates a new directory Path, and sets the new directory’s mode to Mode. Path can be
an absolute path or a relative path. Note that only the last element of the directory will be created,
higher level directories must already exist, and must be writeable by the current user.
On succes, 0 is returned. if the function fails, -1 is returned.
Note: There exist a portable alterative to fpMkDir: system.mkdir. Please use fpMkDir only if you
are writing Unix specific code. System.mkdir will work on all operating systems.
Errors: Extended error information can be retrieved using fpGetErrno (185).
See also: fpGetCWD (183), fpChDir (172)
1.4.43 FpMkfifo
Synopsis: Create FIFO (named pipe) in file system
Declaration: function FpMkfifo(path: PChar; Mode: TMode) : cint
function FpMkfifo(const path: RawByteString; Mode: TMode) : cint
Visibility: default
Description: fpMkFifo creates named a named pipe in the filesystem, with name Path and mode Mode.
The function returns zero if the command was succesful, and nonzero if it failed.
Errors: The error codes include:
sys_emfileToo many file descriptors for this process.
sys_enfileThe system file table is full.
1.4.44 Fpmmap
Synopsis: Create memory map of a file
Declaration: function Fpmmap(start: pointer; len: size_t; prot: cint; flags: cint;
fd: cint; offst: off_t) : pointer
Visibility: default
193
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
Description: FpMMap maps or unmaps files or devices into memory. The different arguments determine what
and how the file is mapped:
adrAddress where to mmap the device. This address is a hint, and may not be followed.
lenSize (in bytes) of area to be mapped.
protProtection of mapped memory. This is a OR-ed combination of the following constants:
PROT_EXECThe memory can be executed.
PROT_READThe memory can be read.
PROT_WRITEThe memory can be written.
PROT_NONEThe memory can not be accessed.
flagsContains some options for the mmap call. It is an OR-ed combination of the following constants:
MAP_FIXEDDo not map at another address than the given address. If the address cannot be
used, MMap will fail.
MAP_SHAREDShare this map with other processes that map this object.
MAP_PRIVATECreate a private map with copy-on-write semantics.
MAP_ANONYMOUSfd does not have to be a file descriptor.
One of the options MAP_SHARED and MAP_PRIVATE must be present, but not both at the
same time.
fdFile descriptor from which to map.
offOffset to be used in file descriptor fd.
The function returns a pointer to the mapped memory, or a -1 in case of en error.
Errors: On error, -1 is returned and extended error information is returned by the FpGetErrno (185) function.
Sys_EBADFfd is not a valid file descriptor and MAP_ANONYMOUS was not specified.
Sys_EACCESMAP_PRIVATE was specified, but fd is not open for reading. Or MAP_SHARED was
asked and PROT_WRITE is set, fd is not open for writing
Sys_EINVALOne of the record fields Start, length or offset is invalid.
Sys_ETXTBUSYMAP_DENYWRITE was set but the object specified by fd is open for writing.
Sys_EAGAINfd is locked, or too much memory is locked.
Sys_ENOMEMNot enough memory for this operation.
See also: FpMUnMap (195)
Listing: ./unixex/ex66.pp
Program Example66 ;
{ Program t o demonstrate t h e MMap f u n c t i o n . }
Uses BaseUnix , Unix ;
Var S : String ;
fd : cint ;
Len : longint ;
// args : tmmapargs ;
P : PChar ;
begin
s := ’ This i s the s t r i n g ’ ;
194
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
Len : = Length (S ) ;
f d : = fpOpen ( ’ t e s t f i l e . t x t ’ , O_wrOnly or o _ c r e a t ) ;
I f f d =−1 then
Halt ( 1 ) ;
I f f p W r i t e ( fd , S [ 1 ] , Len)= −1 then
Halt ( 2 ) ;
fpClose ( fd ) ;
f d : = fpOpen ( ’ t e s t f i l e . t x t ’ , O_rdOnly ) ;
i f f d =−1 then
Halt ( 3 ) ;
P: = Pchar ( fpmmap ( n i l , l e n + 1 ,PROT_READ or PROT_WRITE, MAP_PRIVATE, fd , 0 ) ) ;
I f l o n g i n t (P)= −1 then
Halt ( 4 ) ;
W r i t e l n ( ’ Read i n memory : ’ ,P ) ;
fpclose ( fd ) ;
i f fpMUnMap ( P , Len ) < >0 Then
Halt ( fpgeterrno ) ;
end .
1.4.45 Fpmunmap
Synopsis: Unmap previously mapped memory block
Declaration: function Fpmunmap(start: pointer; len: size_t) : cint
Visibility: default
Description: FpMUnMap unmaps the memory block of size Len, pointed to by Adr, which was previously
allocated with FpMMap (193).
The function returns True if successful, False otherwise.
For an example, see FpMMap (193).
Errors: In case of error the function returns a nonzero value, extended error information is returned by the
FpGetErrno (185) function. See FpMMap (193) for possible error values.
See also: FpMMap (193)
1.4.46 FpNanoSleep
Synopsis: Suspend process for a short time
Declaration: function FpNanoSleep(req: ptimespec; rem: ptimespec) : cint
Visibility: default
Description: FpNanoSleep suspends the process till a time period as specified in req has passed. Then the
function returns. If the call was interrupted (e.g. by some signal) then the function may return earlier,
and rem will contain the remaining time till the end of the intended period. In this case the return
value will be -1, and ErrNo will be set to EINTR
If the function returns without error, the return value is zero.
Errors: If an error occurred or the call was interrupted, -1 is returned. Extended error information can be
retrieved using fpGetErrno (185).
See also: FpPause (199), FpAlarm (172)
195
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
Listing: ./bunixex/ex72.pp
program example72 ;
{ Program t o demonstrate t h e NanoSleep f u n c t i o n . }
uses BaseUnix ;
Var
Req ,Rem : TimeSpec ;
Res : L o n g i n t ;
begin
With Req do
begin
tv_sec :=10;
tv_nsec : = 1 0 0 ;
end ;
Write ( ’ NanoSleep r e t u r n e d : ’ ) ;
Flush ( Output ) ;
Res : = ( fpNanoSleep (@Req,@rem ) ) ;
Writeln ( res ) ;
I f ( res < >0) then
With rem do
begin
W r i t e l n ( ’ Remaining seconds : ’ , tv_sec ) ;
W r i t e l n ( ’ Remaining nanoseconds : ’ , tv_nsec ) ;
end ;
end .
1.4.47 fpNice
Synopsis: Set process priority
Declaration: function fpNice(N: cint) : cint
Visibility: default
Description: Nice adds -N to the priority of the running process. The lower the priority numerically, the less the
process is favored. Only the superuser can specify a negative N, i.e. increase the rate at which the
process is run.
If the function is succesful, zero is returned. On error, a nonzero value is returned.
Errors: Extended error information is returned by the FpGetErrno (185) function.
sys_epermA non-superuser tried to specify a negative N, i.e. do a priority increase.
See also: FpGetPriority (187), FpSetPriority (207)
Listing: ./unixex/ex15.pp
Program Example15 ;
{ Program t o demonstrate t h e Nice and Get / S e t P r i o r i t y f u n c t i o n s . }
Uses BaseUnix , Unix ;
196
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
begin
writeln ( ’ Setting p r i o r i t y to 5 ’ ) ;
f p s e t p r i o r i t y ( prio_process , fpgetpid , 5 ) ;
w r i t e l n ( ’New p r i o r i t y = ’ , f p g e t p r i o r i t y ( p r i o _ p r o c e s s , f p g e t p i d ) ) ;
w r i t e l n ( ’ Doing n i c e 1 0 ’ ) ;
fpnice ( 1 0 ) ;
w r i t e l n ( ’New P r i o r i t y = ’ , f p g e t p r i o r i t y ( p r i o _ p r o c e s s , f p g e t p i d ) ) ;
end .
1.4.48 FpOpen
Synopsis: Open file and return file descriptor
Declaration: function FpOpen(path: PChar; flags: cint; Mode: TMode) : cint
function FpOpen(path: PChar; flags: cint) : cint
function FpOpen(const path: RawByteString; flags: cint) : cint
function FpOpen(const path: RawByteString; flags: cint; Mode: TMode)
: cint
function FpOpen(path: ShortString; flags: cint) : cint
function FpOpen(path: ShortString; flags: cint; Mode: TMode) : cint
Visibility: default
Description: FpOpen opens a file in Path with flags flags and mode Mode One of the following:
O_RdOnlyFile is opened Read-only
O_WrOnlyFile is opened Write-only
O_RdWrFile is opened Read-Write
The flags may beOR-ed with one of the following constants:
O_CreatFile is created if it doesn’t exist.
O_ExclIf the file is opened with O_Creat and it already exists, the call wil fail.
O_NoCttyIf the file is a terminal device, it will NOT become the process’ controlling terminal.
O_TruncIf the file exists, it will be truncated.
O_Appendthe file is opened in append mode. Before each write, the file pointer is positioned at the
end of the file.
O_NonBlockThe file is opened in non-blocking mode. No operation on the file descriptor will cause
the calling process to wait till.
O_NDelayIdem as O_NonBlock
O_SyncThe file is opened for synchronous IO. Any write operation on the file will not return untill
the data is physically written to disk.
O_NoFollowif the file is a symbolic link, the open fails. (Linux 2.1.126 and higher only)
O_Directoryif the file is not a directory, the open fails. (Linux 2.1.126 and higher only)
Path can be of type PChar or String. The optional mode argument specifies the permissions
to set when opening the file. This is modified by the umask setting. The real permissions are Mode
and not umask. The return value of the function is the filedescriptor, or a negative value if there
was an error.
Errors: Extended error information can be retrieved using fpGetErrno (185).
197
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
See also: FpClose (175), FpRead (201), FpWrite (222), FpFTruncate (183), FpLSeek (191)
Listing: ./bunixex/ex19.pp
Program Example19 ;
{ Program t o demonstrate t h e fdOpen , f d w r i t e and fdCLose f u n c t i o n s . }
Uses BaseUnix ;
Const L i n e : S t r i n g [ 8 0 ] = ’ T h i s i s easy w r i t i n g ! ’ ;
Var FD : C i n t ;
begin
FD: = fpOpen ( ’ Test . d a t ’ , O_WrOnly or O_Creat ) ;
i f FD>0 then
begin
i f length ( L i n e )<> f p w r i t e ( FD, L i n e [ 1 ] , Length ( L i n e ) ) then
W r i t e l n ( ’ E r r o r when w r i t i n g t o f i l e ! ’ ) ;
f p C l o s e (FD ) ;
end ;
end .
1.4.49 FpOpendir
Synopsis: Open a directory for reading
Declaration: function FpOpendir(dirname: PChar) : pDir
function FpOpendir(const dirname: RawByteString) : pDir
function FpOpendir(dirname: ShortString) : pDir
Visibility: default
Description: FpOpenDir opens the directory DirName, and returns a pdir pointer to a Dir (154) record, which
can be used to read the directory structure. If the directory cannot be opened, nil is returned.
Errors: Extended error information can be retrieved using fpGetErrno (185).
See also: FpCloseDir (175), FpReadDir (202)
Listing: ./bunixex/ex35.pp
Program Example35 ;
{ Program t o demonstrate t h e
OpenDir , ReadDir , SeekDir and T e l l D i r f u n c t i o n s . }
Uses BaseUnix ;
Var TheDir : PDir ;
ADirent : PDirent ;
Entry : Longint ;
begin
TheDir : = fpOpenDir ( ’ . / . ’ ) ;
Repeat
// E n t r y : = f p T e l l D i r ( TheDir ) ;
198
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
A D i r e n t : = fpReadDir ( TheDir ^ ) ;
I f ADirent <> N i l then
With A D i r e n t ^ do
begin
W r i t e l n ( ’ E n t r y No : ’ , E n t r y ) ;
W r i t e l n ( ’ Inode : ’ , d_fileno ) ;
// Writeln ( ’ Offset : ’ , d_off ) ;
W r i t e l n ( ’ Reclen : ’ , d_reclen ) ;
W r i t e l n ( ’Name : ’ , pchar (@d_name [ 0 ] ) ) ;
end ;
Until ADirent=Nil ;
Repeat
Write ( ’ E n t r y No . you would l i k e t o see again ( − 1 t o s t o p ) : ’ ) ;
ReadLn ( E n t r y ) ;
I f Entry <>−1 then
begin
// f p S e e k D i r ( TheDir , E n t r y ) ; / / n o t implemented f o r v a r i o u s p l a t f o r m s
A D i r e n t : = fpReadDir ( TheDir ^ ) ;
I f ADirent <> N i l then
With A D i r e n t ^ do
begin
W r i t e l n ( ’ E n t r y No : ’ , E n t r y ) ;
W r i t e l n ( ’ Inode : ’ , d_fileno ) ;
// Writeln ( ’ Offset : ’ , off );
W r i t e l n ( ’ Reclen : ’ , d_reclen ) ;
W r i t e l n ( ’Name : ’ , pchar (@d_name [ 0 ] ) ) ;
end ;
end ;
U n t i l E n t r y =−1;
f p C l o s e D i r ( TheDir ^ ) ;
end .
1.4.50 FpPause
Synopsis: Wait for a signal to arrive
Declaration: function FpPause : cint
Visibility: default
Description: FpPause puts the process to sleep and waits until the application receives a signal. If a signal
handler is installed for the received sigal, the handler will be called and after that pause will return
control to the process.
For an example, see fpAlarm (172).
1.4.51 FpPipe
Synopsis: Create a set of pipe file handlers
Declaration: function FpPipe(var fildes: TFilDes) : cint
Visibility: default
Description: FpPipe creates a pipe, i.e. two file objects, one for input, one for output. The filehandles are
returned in the array fildes. The input handle is in the 0-th element of the array, the output handle
is in the 1-st element.
The function returns zero if everything went succesfully, a nonzero return value indicates an error.
199
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
Errors: In case the function fails, the following return values are possible:
sys_emfileToo many file descriptors for this process.
sys_enfileThe system file table is full.
See also: #rtl.unix.POpen (1956), fpMkFifo (193)
Listing: ./bunixex/ex36.pp
Program Example36 ;
{ Program t o demonstrate t h e AssignPipe f u n c t i o n . }
Uses BaseUnix , Unix ;
Var p i p i , p i p o : Text ;
s : String ;
begin
W r i t e l n ( ’ A s s i g n i n g Pipes . ’ ) ;
I f a s s i g n p i p e ( p i p i , p i p o ) < >0 then
Writeln ( ’ Error assigning pipes ! ’ , fpgeterr no ) ;
W r i t e l n ( ’ W r i t i n g t o pipe , and f l u s h i n g . ’ ) ;
W r i t e l n ( pipo , ’ T h i s i s a t e x t s t r i n g ’ ) ; c l o s e ( p i p o ) ;
W r i t e l n ( ’ Reading from p i p e . ’ ) ;
While not eof ( p i p i ) do
begin
Readln ( p i p i , s ) ;
W r i t e l n ( ’ Read from p i p e : ’ , s ) ;
end ;
close ( p i p i ) ;
w r i t e l n ( ’ Closed p i p e s . ’ ) ;
writeln
end .
1.4.52 FpPoll
Synopsis: Poll a file descriptor for events.
Declaration: function FpPoll(fds: ppollfd; nfds: cuint; timeout: clong) : cint
Visibility: default
Description: fpPoll waits for events on file descriptors. fds points to an array of tpollfd records, each of
these records describes a file descriptor on which to wait for events. The number of file descriptors
is given by nfds. >timeout specifies the maximum time (in milliseconds) to wait for events.
On timeout, the result value is 0. If an event occurred on some descriptors, then the return value is the
number of descriptors on which an event (or error) occurred. The revents field of the tpollfd
records will contain the events for the file descriptor it described.
See also: tpollfd (166)
1.4.53 FppRead
Synopsis: Positional read: read from file descriptor at a certain position.
200
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
Declaration: function FpPRead(fd: cint; buf: PChar; nbytes: TSize; offset: TOff)
: TsSize
function FppRead(fd: cint; var buf; nbytes: TSize; offset: TOff)
: TsSize
Visibility: default
Description: FpPRead reads nbytes bytes from file descriptor fd into buffer buf starting at offset offset.
Offset is measured from the start of the file. This function can only be used on files, not on pipes
or sockets (i.e. any seekable file descriptor).
The function returns the number of bytes actually read, or -1 on error.
Errors: On error, -1 is returned.
See also: FpReadV (204), FpPWrite (201)
1.4.54 FppWrite
Synopsis: Positional write: write to file descriptor at a certain position.
Declaration: function FpPWrite(fd: cint; buf: PChar; nbytes: TSize; offset: TOff)
: TsSize
function FppWrite(fd: cint; const buf; nbytes: TSize; offset: TOff)
: TsSize
Visibility: default
Description: FpPWrite writes nbytes bytes from buffer buf into file descriptor fd starting at offset offset.
Offset is measured from the start of the file. This function can only be used on files, not on pipes
or sockets (i.e. any seekable file descriptor).
The function returns the number of bytes actually written, or -1 on error.
Errors: On error, -1 is returned.
See also: FpPRead (200), FpWriteV (223)
1.4.55 FpRead
Synopsis: Read data from file descriptor
Declaration: function FpRead(fd: cint; buf: PChar; nbytes: TSize) : TsSize
function FpRead(fd: cint; var buf; nbytes: TSize) : TsSize
Visibility: default
Description: FpdRead reads at most nbytes bytes from the file descriptor fd, and stores them in buf.
The function returns the number of bytes actually read, or -1 if an error occurred. No checking on
the length of buf is done.
Errors: Extended error information can be retrieved using fpGetErrno (185).
See also: FpOpen (197), FpClose (175), FpWrite (222), FpFTruncate (183), FpLSeek (191)
Listing: ./bunixex/ex20.pp
201
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
Program Example20 ;
{ Program t o demonstrate t h e fdRead and f d T r u n c a t e f u n c t i o n s . }
Uses BaseUnix ;
Const Data : s t r i n g [ 1 0 ] = ’ 1234567890 ’ ;
Var FD : c i n t ;
l : longint ;
begin
FD: = fpOpen ( ’ t e s t . d a t ’ , o_wronly or o_creat , & 6 6 6 ) ;
i f fd >0 then
begin
{ F i l l f i l e w i t h data }
f o r l : = 1 to 1 0 do
i f f p W r i t e ( FD, Data [ 1 ] , 1 0 ) < > 1 0 then
begin
w r i t e l n ( ’ E r r o r when w r i t i n g ! ’ ) ;
halt ( 1 ) ;
end ;
f p C l o s e (FD ) ;
FD: = fpOpen ( ’ t e s t . d a t ’ , o _ r d o n l y ) ;
{ Read data again }
I f FD>0 then
begin
For l : = 1 to 5 do
i f fpRead ( FD, Data [ 1 ] , 1 0 ) < > 1 0 then
begin
W r i t e l n ( ’ E r r o r when Reading ! ’ ) ;
Halt ( 2 ) ;
end ;
f p C l o s e (FD ) ;
{ Truncating f i l e at 6 0 bytes }
{ For t r u n c a t i n g , f i l e must be open o r w r i t e }
FD: = fpOpen ( ’ t e s t . d a t ’ , o_wronly , & 6 6 6 ) ;
i f FD>0 then
begin
i f f p f T r u n c a t e (FD,60) < >0 then
W r i t e l n ( ’ E r r o r when t r u n c a t i n g ! ’ ) ;
f p C l o s e ( FD ) ;
end ;
end ;
end ;
end .
1.4.56 FpReaddir
Synopsis: Read entry from directory
Declaration: function FpReaddir(var dirp: Dir) : pDirent
Visibility: default
Description: FpReadDir reads the next entry in the directory pointed to by dirp. It returns a pdirent pointer
to a dirent (155) record describing the entry. If the next entry can’t be read, Nil is returned.
202
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
For an example, see FpOpenDir (198).
Errors: Extended error information can be retrieved using fpGetErrno (185).
See also: FpCloseDir (175), FpOpenDir (198)
1.4.57 fpReadLink
Synopsis: Read destination of symbolic link
Declaration: function fpReadLink(name: PChar; linkname: PChar; maxlen: size_t) : cint
function fpReadLink(const Name: RawByteString) : RawByteString
Visibility: default
Description: FpReadLink returns the file the symbolic link name is pointing to. The first form of this function
accepts a buffer linkname of length maxlen where the filename will be stored. It returns the
actual number of characters stored in the buffer.
The second form of the function returns simply the name of the file.
Errors: On error, the first form of the function returns -1; the second one returns an empty string. Extended
error information is returned by the FpGetErrno (185) function.
SYS_ENOTDIRA part of the path in Name is not a directory.
SYS_EINVALmaxlen is not positive, or the file is not a symbolic link.
SYS_ENAMETOOLONGA pathname, or a component of a pathname, was too long.
SYS_ENOENTthe link name does not exist.
SYS_EACCESNo permission to search a directory in the path
SYS_ELOOPToo many symbolic links were encountered in translating the pathname.
SYS_EIOAn I/O error occurred while reading from the file system.
SYS_EFAULTThe buffer is not part of the process’s memory space.
SYS_ENOMEMNot enough kernel memory was available.
See also: FpSymLink (215)
Listing: ./unixex/ex62.pp
Program Example62 ;
{ Program t o demonstrate t h e ReadLink f u n c t i o n . }
Uses BaseUnix , Unix ;
Var F : Text ;
S : String ;
begin
Assign ( F , ’ t e s t . t x t ’ ) ;
Rewrite ( F ) ;
Writeln ( F , ’ This i s w r i t t e n to t e s t . t x t ’ ) ;
Close ( f ) ;
{ new . t x t and t e s t . t x t are now t h e same f i l e }
i f fpSymLink ( ’ t e s t . t x t ’ , ’ new . t x t ’ ) < >0 then
w r i t e l n ( ’ E r r o r when s y m l i n k i n g ! ’ ) ;
S: = fpReadLink ( ’ new . t x t ’ ) ;
203
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
I f S= ’ ’ then
Writeln ( ’ Error reading l i n k ! ’ )
Else
W r i t e l n ( ’ L i n k p o i n t s t o : ’ ,S ) ;
{ Now remove l i n k s }
I f f p U n l i n k ( ’ new . t x t ’ ) < >0 then
W r i t e l n ( ’ E r r o r when u n l i n k i n g ! ’ ) ;
I f f p U n l i n k ( ’ t e s t . t x t ’ ) < >0 then
W r i t e l n ( ’ E r r o r when u n l i n k i n g ! ’ ) ;
end .
1.4.58 FpReadV
Synopsis: Vector read: Read into multiple buffers
Declaration: function FpReadV(fd: cint; const iov: piovec; iovcnt: cint) : TsSize
Visibility: default
Description: FpReadV reads data from file descriptor fd and writes it into iovcnt buffers described by the
tiovec (166) buffers pointed to by iov. It works like fpRead (201) only on multiple buffers.
Errors: On error, -1 is returned.
See also: FpWriteV (223), FpPWrite (201), FpPRead (200)
1.4.59 FpRename
Synopsis: Rename file
Declaration: function FpRename(old: PChar; newpath: PChar) : cint
function FpRename(const old: RawByteString;
const newpath: RawByteString) : cint
Visibility: default
Description: FpRename renames the file Old to NewPath. NewPath can be in a different directory than Old,
but it cannot be on another partition (device). Any existing file on the new location will be replaced.
If the operation fails, then the Old file will be preserved.
The function returns zero on succes, a nonzero value indicates failure.
Note: There exist a portable alterative to fpRename: system.rename. Please use fpRename only if
you are writing Unix specific code. System.rename will work on all operating systems.
Errors: Extended error information can be retrieved using fpGetErrno (185).
sys_eisdirNewPath exists and is a directory, but Old is not a directory.
sys_exdevNewPath and Old are on different devices.
sys_enotempty or sys_eexistNewPath is an existing, non-empty directory.
sys_ebusyOld or NewPath is a directory and is in use by another process.
sys_einvalNewPath is part of Old.
sys_emlinkOldPath or NewPath already have tha maximum amount of links pointing to them.
sys_enotdirpart of Old or NewPath is not directory.
sys_efaultFor the pchar case: One of the pointers points to an invalid address.
204
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
sys_eaccessaccess is denied when attempting to move the file.
sys_enametoolongEither Old or NewPath is too long.
sys_enoenta directory component in Old or NewPath didn’t exist.
sys_enomemnot enough kernel memory.
sys_erofsNewPath or Old is on a read-only file system.
sys_elooptoo many symbolic links were encountered trying to expand Old or NewPath
sys_enospcthe filesystem has no room for the new directory entry.
See also: FpUnLink (220)
1.4.60 FpRmdir
Synopsis: Remove a directory.
Declaration: function FpRmdir(path: PChar) : cint
function FpRmdir(const path: RawByteString) : cint
Visibility: default
Description: FpRmdir removes the directory Path from the system. The directory must be empty for this call
to succeed, and the user must have the necessary permissions in the parent directory. Only the last
component of the directory is removed, i.e. higher-lying directories are not removed.
On success, zero is returned. A nonzero return value indicates failure.
Note: There exist a portable alterative to fpRmDir: system.rmdir. Please use fpRmDir only if you
are writing Unix specific code. System.rmdir will work on all operating systems.
Errors: Extended error information can be retrieved using fpGetErrno (185).
1.4.61 fpSelect
Synopsis: Wait for events on file descriptors
Declaration: function FPSelect(N: cint; readfds: pFDSet; writefds: pFDSet;
exceptfds: pFDSet; TimeOut: ptimeval) : cint
function fpSelect(N: cint; readfds: pFDSet; writefds: pFDSet;
exceptfds: pFDSet; TimeOut: cint) : cint
function fpSelect(var T: Text; TimeOut: ptimeval) : cint
function fpSelect(var T: Text; TimeOut: time_t) : cint
Visibility: default
Description: FpSelect checks one of the file descriptors in the FDSets to see if the following I/O operation
on the file descriptors will block.
readfds, writefds and exceptfds are pointers to arrays of 256 bits. If you want a file
descriptor to be checked, you set the corresponding element in the array to 1. The other elements
in the array must be set to zero. Three arrays are passed : The entries in readfds are checked to
see if the following read operation will block. The entries in writefds are checked to see if the
following write operation will block, while entries in exceptfds are checked to see if an exception
occorred on them.
You can use the functions fpFD_ZERO (181), fpFD_Clr (181), fpFD_Set (181) or fpFD_IsSet (181)
to manipulate the individual elements of a set.
The pointers can be Nil.
205
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
N is the value of the largest file descriptor in one of the sets, + 1. In other words, it is the position of
the last bit which is set in the array of bits.
TimeOut can be used to set a time limit. If TimeOut can be two types :
1.TimeOut is of type ptimeval and contains a zero time, the call returns immediately. If
TimeOut is Nil, the kernel will wait forever, or until a status changed.
2.TimeOut is of type cint. If it is -1, this has the same effect as a Timeout of type PTime
which is Nil. Otherwise, TimeOut contains a time in milliseconds.
When the TimeOut is reached, or one of the file descriptors has changed, the Select call returns.
On return, it will have modified the entries in the array which have actually changed, and it returns
the number of entries that have been changed. If the timout was reached, and no decsriptor changed,
zero is returned; The arrays of indexes are undefined after that. On error, -1 is returned.
The variant with the text file will execute the FpSelect call on the file descriptor associated with
the text file T
Errors: On error, the function returns -1. Extended error information can be retrieved using fpGetErrno
(185).
SYS_EBADFAn invalid descriptor was specified in one of the sets.
SYS_EINTRA non blocked signal was caught.
SYS_EINVALN is negative or too big.
SYS_ENOMEMSelect was unable to allocate memory for its internal tables.
See also: fpFD_ZERO (181), fpFD_Clr (181), fpFD_Set (181), fpFD_IsSet (181)
Listing: ./bunixex/ex33.pp
Program Example33 ;
{ Program t o demonstrate t h e S e l e c t f u n c t i o n . }
Uses BaseUnix ;
Var FDS : T f d s e t ;
begin
f p f d _ z e r o (FDS ) ;
f p f d _ s e t ( 0 ,FDS ) ;
W r i t e l n ( ’ Press t h e <ENTER> t o c o n t i n u e t h e program . ’ ) ;
{ Wait u n t i l F i l e d e s c r i p t o r 0 ( = I n p u t ) changes }
f p S e l e c t ( 1 ,@FDS, n i l , n i l , n i l ) ;
{ Get r i d o f <ENTER> i n b u f f e r }
readln ;
W r i t e l n ( ’ Press <ENTER> key i n l e s s than 2 seconds . . . ’ ) ;
Fpfd_zero (FDS ) ;
FpFd_set ( 0 , FDS ) ;
i f f p S e l e c t ( 1 ,@FDS, n i l , n i l , 2 0 0 0 ) > 0 then
W r i t e l n ( ’ Thank you ! ’ )
{ FD_ISSET ( 0 ,FDS ) would be t r u e here . }
else
W r i t e l n ( ’ Too l a t e ! ’ ) ;
end .
206
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
1.4.62 fpseterrno
Synopsis: Set extended error information.
Declaration: procedure fpseterrno(err: LongInt)
Visibility: default
Description: fpseterrno sets the extended information on the latest error. It is called by all functions that
communicate with the kernel or C library.
Unless a direct kernel call is performed, there should never be any need to call this function.
See also: fpgeterrno (185)
1.4.63 FpSetgid
Synopsis: Set the current group ID
Declaration: function FpSetgid(gid: TGid) : cint
Visibility: default
Description: fpSetUID sets the group ID of the current process. This call will only work if it is executed as
root, or the program is setgid root.
On success, zero is returned, on error -1 is returned.
Errors: Extended error information can be retrieved with fpGetErrNo (185).
See also: FpSetUid (208), FpGetGid (185), FpGetUid (188), FpGetEUid (185), FpGetEGid (184), FpGetPid
(186), FpGetPPid (187)
1.4.64 fpSetPriority
Synopsis: Set process priority
Declaration: function fpSetPriority(Which: cint; Who: cint; What: cint) : cint
Visibility: default
Description: fpSetPriority sets the priority with which a process is running. Which process(es) is deter-
mined by the Which and Who variables. Which can be one of the pre-defined constants:
Prio_ProcessWho is interpreted as process ID
Prio_PGrpWho is interpreted as process group ID
Prio_UserWho is interpreted as user ID
Prio is a value in the range -20 to 20.
For an example, see FpNice (196).
The function returns zero on success, -1 on failure
Errors: Extended error information is returned by the FpGetErrno (185) function.
sys_esrchNo process found using which and who.
sys_einvalWhich was not one of Prio_Process, Prio_Grp or Prio_User.
sys_epermA process was found, but neither its effective or real user ID match the effective user ID
of the caller.
sys_eaccesA non-superuser tried to a priority increase.
See also: FpGetPriority (187), FpNice (196)
207
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
1.4.65 FpSetRLimit
Synopsis: Set process resource limits
Declaration: function FpSetRLimit(Resource: cint; rlim: PRLimit) : cint
Visibility: default
Description: FpGetRLimit sets the resource limits for the current process: resource determines the resource
of which the kernel should set the limits (one of the many RLIMIT_* constants). rlim should point
to a TRLimit (166) record which contains the new limits for the resource indicated in resource.
The function returns zero if the resource limits were successfully set.
Errors: On error, -1 is returned and fpgeterrno (185) can be used to retrieve the error code.
See also: FpGetRLimit (188)
1.4.66 FpSetsid
Synopsis: Create a new session.
Declaration: function FpSetsid : TPid
Visibility: default
Description: FpSetsid creates a new session (process group). It returns the new process group id (as returned
by FpGetpgrp (186). This call will fail if the current process is already the process group leader.
Errors: On error, -1 is returned. Extended error information can be retrieved with fpGetErrNo (185)
1.4.67 fpsettimeofday
Synopsis: Set kernel time
Declaration: function fpsettimeofday(tp: ptimeval; tzp: ptimezone) : cint
Visibility: default
Description: FpSetTimeOfDay sets the kernel time to the number of seconds since 00:00, January 1 1970,
GMT specified in the tp record. This time NOT corrected any way, not taking into account time-
zones, daylight savings time and so on.
It is simply a wrapper to the kernel system call.
See also: #rtl.unix.FPGetTimeOfDay (1952)
1.4.68 FpSetuid
Synopsis: Set the current user ID
Declaration: function FpSetuid(uid: TUid) : cint
Visibility: default
Description: fpSetUID sets the user ID of the current process. This call will only work if it is executed as root,
or the program is setuid root.
On success, zero is returned, on error -1 is returned.
Errors: Extended error information can be retrieved with fpGetErrNo (185).
See also: FpGetGid (185), FpGetUid (188), FpGetEUid (185), FpGetEGid (184), FpGetPid (186), FpGetPPid
(187), FpSetGid (207)
208
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
1.4.69 FPSigaction
Synopsis: Install signal handler
Declaration: function FPSigaction(sig: cint; act: psigactionrec; oact: psigactionrec)
: cint
Visibility: default
Description: FPSigaction changes the action to take upon receipt of a signal. Act and Oact are pointers to
a SigActionRec (162) record. Sig specifies the signal, and can be any signal except SIGKILL or
SIGSTOP.
If Act is non-nil, then the new action for signal Sig is taken from it. If OAct is non-nil, the old
action is stored there. Sa_Handler may be SIG_DFL for the default action or SIG_IGN to ignore
the signal. Sa_Mask Specifies which signals should be ignord during the execution of the signal
handler. Sa_Flags Speciefies a series of flags which modify the behaviour of the signal handler.
You can ’or’ none or more of the following :
SA_NOCLDSTOPIf sig is SIGCHLD do not receive notification when child processes stop.
SA_ONESHOT or SA_RESETHANDRestore the signal action to the default state once the signal
handler has been called.
SA_RESTARTFor compatibility with BSD signals.
SA_NOMASK or SA_NODEFERDo not prevent the signal from being received from within its
own signal handler.
Errors: Extended error information can be retrieved using fpGetErrno (185).
sys_einvalan invalid signal was specified, or it was SIGKILL or SIGSTOP.
sys_efaultAct,OldAct point outside this process address space
sys_eintrSystem call was interrupted.
See also: FpSigProcMask (212), FpSigPending (212), FpSigSuspend (213), FpKill (189)
Listing: ./bunixex/ex57.pp
Program example57 ;
{ Program t o demonstrate t h e S i g A c t i o n f u n c t i o n . }
{
do a k i l l −USR1 p i d from a n o t h e r t e r m i n a l t o see what happens .
r e p l a c e p i d w i t h t h e r e a l p i d o f t h i s program .
You can g e t t h i s p i d by r u n n i n g ’ ps ’ .
}
uses BaseUnix ;
Var
oa , na : PSigActionRec ;
Procedure DoSig ( s i g : c i n t ) ; cdecl ;
begin
writeln ( ’ Receiving s i g n a l : ’ , sig ) ;
end ;
209
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
begin
new( na ) ;
new( oa ) ;
na ^ . sa_Handler : = S i g A c t i o n H a n d l e r ( @DoSig ) ;
f i l l c h a r ( na ^ . Sa_Mask , s i z e o f ( na ^ . sa_mask ) , # 0 ) ;
na ^ . Sa_Flags : = 0 ;
{ $ i f d e f Linux } / / Linux s p e c i f i c
na ^ . Sa_Restorer : = N i l ;
{ $endif }
i f f p S i g A c t i o n ( SigUsr1 , na , oa ) < >0 then
begin
writeln ( ’ Error : ’ , fpgeterrno , ’ . ’ ) ;
halt ( 1 ) ;
end ;
W r i t e l n ( ’ Send USR1 s i g n a l o r press <ENTER> t o e x i t ’ ) ;
readln ;
end .
1.4.70 FpSigAddSet
Synopsis: Set a signal in a signal set.
Declaration: function FpSigAddSet(var nset: tsigset; signo: cint) : cint
Visibility: default
Description: FpSigAddSet adds signal Signo to the signal set nset. The function returns 0 on success.
Errors: If an invalid signal number is given, -1 is returned.
See also: FpSigEmptySet (210), FpSigFillSet (211), FpSigDelSet (210), FpSigIsMember (211)
1.4.71 FpSigDelSet
Synopsis: Remove a signal from a signal set.
Declaration: function FpSigDelSet(var nset: tsigset; signo: cint) : cint
Visibility: default
Description: FpSigDelSet removes signal Signo to the signal set nset. The function returns 0 on success.
Errors: If an invalid signal number is given, -1 is returned.
See also: FpSigEmptySet (210), FpSigFillSet (211), FpSigAddSet (210), FpSigIsMember (211)
1.4.72 FpsigEmptySet
Synopsis: Clear all signals from signal set.
Declaration: function FpsigEmptySet(var nset: tsigset) : cint
Visibility: default
Description: FpSigEmptySet clears all signals from the signal set nset.
Errors: None. This function always returns zero.
See also: FpSigFillSet (211), FpSigAddSet (210), FpSigDelSet (210), FpSigIsMember (211)
210
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
1.4.73 FpSigFillSet
Synopsis: Set all signals in signal set.
Declaration: function FpSigFillSet(var nset: tsigset) : cint
Visibility: default
Description: FpSigFillSet sets all signals in the signal set nset.
Errors: None. This function always returns zero.
See also: FpSigEmptySet (210), FpSigAddSet (210), FpSigDelSet (210), FpSigIsMember (211)
1.4.74 FpSigIsMember
Synopsis: Check whether a signal appears in a signal set.
Declaration: function FpSigIsMember(const nset: tsigset; signo: cint) : cint
Visibility: default
Description: FpSigIsMember checks whether SigNo appears in the set nset. If it is a member, then 1 is
returned. If not, zero is returned.
Errors: If an invalid signal number is given, -1 is returned.
See also: FpSigEmptySet (210), FpSigFillSet (211), FpSigAddSet (210), FpSigDelSet (210)
1.4.75 FpSignal
Synopsis: Install signal handler (deprecated)
Declaration: function FpSignal(signum: LongInt; Handler: signalhandler)
: signalhandler
Visibility: default
Description: FPSignal installs a new signal handler (specified by Handler) for signal SigNum.
This call has a subset of the functionality provided by the FpSigAction (209) call. The return value
for FpSignal is the old signal handler, or nil on error.
Errors: Extended error information can be retrieved using fpGetErrno (185).
SIG_ERRAn error occurred.
See also: FpSigAction (209), FpKill (189)
Listing: ./bunixex/ex58.pp
Program example58 ;
{ Program t o demonstrate t h e S i g n a l f u n c t i o n . }
{
do a k i l l −USR1 p i d from a n o t h e r t e r m i n a l t o see what happens .
r e p l a c e p i d w i t h t h e r e a l p i d o f t h i s program .
You can g e t t h i s p i d by r u n n i n g ’ ps ’ .
}
211
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
uses BaseUnix ;
Procedure DoSig ( s i g : c i n t ) ; cdecl ;
begin
writeln ( ’ Receiving s i g n a l : ’ , sig ) ;
end ;
begin
i f f p S i g n a l ( SigUsr1 , S i g n a l H a n d l e r ( @DoSig ) ) = s i g n a l h a n d l e r ( SIG_ERR ) then
begin
w r i t e l n ( ’ E r r o r : ’ , fpGetErrno , ’ . ’ ) ;
halt ( 1 ) ;
end ;
W r i t e l n ( ’ Send USR1 s i g n a l o r press <ENTER> t o e x i t ’ ) ;
readln ;
end .
1.4.76 FpSigPending
Synopsis: Return set of currently pending signals
Declaration: function FpSigPending(var nset: tsigset) : cint
Visibility: default
Description: fpSigpending allows the examination of pending signals (which have been raised while blocked.)
The signal mask of pending signals is returned.
Errors: None
See also: fpSigAction (209), fpSigProcMask (212), fpSigSuspend (213), fpSignal (211), fpKill (189)
1.4.77 FpSigProcMask
Synopsis: Set list of blocked signals
Declaration: function FpSigProcMask(how: cint; nset: psigset; oset: psigset) : cint
function FpSigProcMask(how: cint; constref nset: tsigset;
var oset: tsigset) : cint
Visibility: default
Description: Changes the list of currently blocked signals. The behaviour of the call depends on How :
SIG_BLOCKThe set of blocked signals is the union of the current set and the nset argument.
SIG_UNBLOCKThe signals in nset are removed from the set of currently blocked signals.
SIG_SETMASKThe list of blocked signals is set so nset.
If oset is non-nil, then the old set is stored in it.
Errors: Errno is used to report errors.
sys_efaultoset or nset point to an adress outside the range of the process.
sys_eintrSystem call was interrupted.
See also: fpSigAction (209), fpSigPending (212), fpSigSuspend (213), fpKill (189)
212
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
1.4.78 FpSigSuspend
Synopsis: Set signal mask and suspend process till signal is received
Declaration: function FpSigSuspend(const sigmask: tsigset) : cint
Visibility: default
Description: fpSigSuspend temporarily replaces the signal mask for the process with the one given in SigMask,
and then suspends the process until a signal is received.
Errors: None
See also: fpSigAction (209), fpSigProcMask (212), fpSigPending (212), fpSignal (211), fpKill (189)
1.4.79 FpSigTimedWait
Synopsis: Wait for signal, with timeout
Declaration: function FpSigTimedWait(const sigset: tsigset; info: psiginfo;
timeout: ptimespec) : cint
Visibility: default
Description: FpSigTimedWait will suspend the current thread and wait for one of the signals in sigset to
be delivered. information on the delivered signal is placed in the location provided by info (or in
info itself, if the Var variant of the call is used). If the signal is not delivered within the time limit
set in timeout, then the call will return -1, and fpGetErrno will return EAGAIN.
On success, the signal number is returned.
Errors: On error, -1 is returned, and extended error information can be obtained with fpGetErrno.
See also: FpSigSuspend (213)
1.4.80 FpSleep
Synopsis: Suspend process for several seconds
Declaration: function FpSleep(seconds: cuint) : cuint
Visibility: default
Description: FpSleep suspends the process till a time period as specified in seconds has passed, then the
function returns. If the call was interrupted (e.g. by some signal) then the function may return
earlier, and the return value is the remaining time till the end of the intended period.
If the function returns without error, the return value is zero.
See also: fpPause (199), fpAlarm (172), fpNanoSleep (195)
Listing: ./bunixex/ex73.pp
program example73 ;
{ Program t o demonstrate t h e FpSleep f u n c t i o n . }
uses BaseUnix ;
Var
213
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
Res : L o n g i n t ;
begin
Write ( ’ Sleep r e t u r n e d : ’ ) ;
Flush ( Output ) ;
Res : = ( f p S l e e p ( 1 0 ) ) ;
Writeln ( res ) ;
I f ( res < >0) then
W r i t e l n ( ’ Remaining seconds : ’ , res ) ;
end .
1.4.81 FpStat
Synopsis: Retrieve file information about a file descriptor.
Declaration: function FpStat(path: PChar; var buf: Stat) : cint
function FpStat(const path: RawByteString; var buf: Stat) : cint
function FpStat(path: ShortString; var buf: Stat) : cint
Visibility: default
Description: FpFStat gets information about the file specified in Path, and stores it in Info, which is of
type stat (164). The function returns zero if the call was succesfull, a nonzero return value indicates
failure.
Errors: Extended error information can be retrieved using fpGetErrno (185).
sys_enoentPath does not exist.
See also: FpStat (214), FpLStat (191)
Listing: ./bunixex/ex28.pp
program example28 ;
{ Program t o demonstrate t h e F S t a t f u n c t i o n . }
uses BaseUnix ;
var f : t e x t ;
i : byte ;
info : stat ;
begin
{ Make a f i l e }
assign ( f , ’ t e s t . f i l ’ ) ;
rewrite ( f ) ;
f o r i : = 1 to 1 0 do w r i t e l n ( f , ’ T e s t l i n e # ’ , i ) ;
close ( f ) ;
{ Do t h e c a l l on made f i l e . }
i f f p s t a t ( ’ t e s t . f i l ’ , i n f o ) < >0 then
begin
w r i t e l n ( ’ F s t a t f a i l e d . Errno : ’ , f p g e t e r r n o ) ;
halt ( 1 ) ;
end ;
writeln ;
w r i t e l n ( ’ R e s u l t o f f s t a t on f i l e ’ ’ t e s t . f i l ’ ’ . ’ ) ;
214
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
w r i t e l n ( ’ Inode : ’ , info . st_ino ) ;
w r i t e l n ( ’ Mode : ’ , info . st_mode ) ;
writeln ( ’ nlink : ’ , info . st_nlink );
writeln ( ’ uid : ’ , info . st_uid ) ;
writeln ( ’ gid : ’ , info . st_gid ) ;
w r i t e l n ( ’ rdev : ’ , info . st_rdev ) ;
w r i t e l n ( ’ Size : ’ , info . st_size ) ;
writeln ( ’ Blksize : ’ , info . st_blksize ) ;
w r i t e l n ( ’ Blocks : ’ , info . st_blocks ) ;
w r i t e l n ( ’ atime : ’ , info . st_atime ) ;
w r i t e l n ( ’ mtime : ’ , info . st_mtime ) ;
writeln ( ’ ctime : ’ , info . st_ctime ) ;
{ Remove f i l e }
erase ( f ) ;
end .
1.4.82 fpSymlink
Synopsis: Create a symbolic link
Declaration: function fpSymlink(oldname: PChar; newname: PChar) : cint
Visibility: default
Description: SymLink makes NewName point to the file in OldName, which doesn’t necessarily exist. The two
files DO NOT have the same inode number. This is known as a ’soft’ link.
The permissions of the link are irrelevant, as they are not used when following the link. Ownership
of the file is only checked in case of removal or renaming of the link.
The function returns zero if the call was succesful, a nonzero value if the call failed.
Errors: Extended error information is returned by the FpGetErrno (185) function.
sys_epermThe filesystem containing oldpath and newpath does not support linking files.
sys_eaccessWrite access for the directory containing Newpath is disallowed, or one of the directo-
ries in OldPath or NewPath has no search (=execute) permission.
sys_enoentA directory entry in OldPath or NewPath does not exist or is a symbolic link pointing
to a non-existent directory.
sys_enotdirA directory entry in OldPath or NewPath is nor a directory.
sys_enomemInsufficient kernel memory.
sys_erofsThe files are on a read-only filesystem.
sys_eexistNewPath already exists.
sys_eloopOldPath or NewPath has a reference to a circular symbolic link, i.e. a symbolic link,
whose expansion points to itself.
sys_enospcThe device containing NewPath has no room for another entry.
See also: FpLink (190), FpUnLink (220), FpReadLink (203)
Listing: ./unixex/ex22.pp
Program Example22 ;
{ Program t o demonstrate t h e SymLink and UnLink f u n c t i o n s . }
215
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
Uses baseunix , Unix ;
Var F : Text ;
S : String ;
begin
Assign ( F , ’ t e s t . t x t ’ ) ;
Rewrite ( F ) ;
Writeln ( F , ’ This i s w r i t t e n to t e s t . t x t ’ ) ;
Close ( f ) ;
{ new . t x t and t e s t . t x t are now t h e same f i l e }
i f fpSymLink ( ’ t e s t . t x t ’ , ’ new . t x t ’ ) < >0 then
w r i t e l n ( ’ E r r o r when s y m l i n k i n g ! ’ ) ;
{ Removing t e s t . t x t s t i l l l e a v e s new . t x t
P o i n t i n g now t o a non−e x i s t e n t f i l e ! }
I f f p U n l i n k ( ’ t e s t . t x t ’ ) < >0 then
W r i t e l n ( ’ E r r o r when u n l i n k i n g ! ’ ) ;
Assign ( f , ’ new . t x t ’ ) ;
{ T h i s should f a i l , s i n c e t h e s y m b o l i c l i n k
p o i n t s t o a non−e x i s t e n t f i l e ! }
{ $ i −}
Reset ( F ) ;
{ $i+}
I f IOResult =0 then
W r i t e l n ( ’ T h i s shouldn ’ ’ t happen ’ ) ;
{ Now remove new . t x t a l s o }
I f f p U n l i n k ( ’ new . t x t ’ ) < >0 then
W r i t e l n ( ’ E r r o r when u n l i n k i n g ! ’ ) ;
end .
1.4.83 fpS_ISBLK
Synopsis: Is file a block device
Declaration: function fpS_ISBLK(m: TMode) : Boolean
Visibility: default
Description: FpS_ISBLK checks the file mode m to see whether the file is a block device file. If so it returns
True.
See also: FpFStat (182), FpS_ISLNK (217), FpS_ISREG (218), FpS_ISDIR (217), FpS_ISCHR (216), FpS_ISFIFO
(217), FpS_ISSOCK (218)
1.4.84 fpS_ISCHR
Synopsis: Is file a character device
Declaration: function fpS_ISCHR(m: TMode) : Boolean
Visibility: default
Description: FpS_ISCHR checks the file mode m to see whether the file is a character device file. If so it returns
True.
See also: FpFStat (182), FpS_ISLNK (217), FpS_ISREG (218), FpS_ISDIR (217), FpS_ISBLK (216), FpS_ISFIFO
(217), FpS_ISSOCK (218)
216
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
1.4.85 fpS_ISDIR
Synopsis: Is file a directory
Declaration: function fpS_ISDIR(m: TMode) : Boolean
Visibility: default
Description: fpS_ISDIR checks the file mode m to see whether the file is a directory. If so, it returns True
See also: FpFStat (182), FpS_ISLNK (217), FpS_ISREG (218), FpS_ISCHR (216), FpS_ISBLK (216), fpS_ISFIFO
(217), FpS_ISSOCK (218)
1.4.86 fpS_ISFIFO
Synopsis: Is file a FIFO
Declaration: function fpS_ISFIFO(m: TMode) : Boolean
Visibility: default
Description: FpS_ISFIFO checks the file mode m to see whether the file is a fifo (a named pipe). If so it returns
True.
See also: FpFStat (182), FpS_ISLNK (217), FpS_ISREG (218), FpS_ISCHR (216), FpS_ISBLK (216), FpS_ISDIR
(217), FpS_ISSOCK (218)
1.4.87 fpS_ISLNK
Synopsis: Is file a symbolic link
Declaration: function fpS_ISLNK(m: TMode) : Boolean
Visibility: default
Description: FpS_ISLNK checks the file mode m to see whether the file is a symbolic link. If so it returns True
See also: FpFStat (182), FpS_ISFIFO (217), FpS_ISREG (218), FpS_ISCHR (216), FpS_ISBLK (216), FpS_ISDIR
(217), FpS_ISSOCK (218)
Listing: ./bunixex/ex53.pp
Program Example53 ;
{ Program t o demonstrate t h e S_ISLNK f u n c t i o n . }
Uses BaseUnix , Unix ;
Var I n f o : S t a t ;
begin
i f f p L S t a t ( paramstr ( 1 ) , @info ) = 0 then
begin
i f fpS_ISLNK ( i n f o . st_mode ) then
Writeln ( ’ F i l e i s a l i n k ’ ) ;
i f fpS_ISREG ( i n f o . st_mode ) then
Writeln ( ’ F i l e i s a r e g u l a r f i l e ’ ) ;
i f fpS_ISDIR ( i n f o . st_mode ) then
Writeln ( ’ F i l e i s a d i r e c t o r y ’ ) ;
217
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
i f fpS_ISCHR ( i n f o . st_mode ) then
Writeln ( ’ F i l e i s a character device f i l e ’ ) ;
i f fpS_ISBLK ( i n f o . st_mode ) then
Writeln ( ’ F i l e i s a block device f i l e ’ ) ;
i f fpS_ISFIFO ( i n f o . st_mode ) then
W r i t e l n ( ’ F i l e i s a named p i p e ( FIFO ) ’ ) ;
i f fpS_ISSOCK ( i n f o . st_mode ) then
Writeln ( ’ F i l e i s a socket ’ ) ;
end ;
end .
1.4.88 fpS_ISREG
Synopsis: Is file a regular file
Declaration: function fpS_ISREG(m: TMode) : Boolean
Visibility: default
Description: FpS_ISREG checks the file mode m to see whether the file is a regular file. If so it returns True
See also: FpFStat (182), FpS_ISFIFO (217), FpS_ISLNK (217), FpS_ISCHR (216), FpS_ISBLK (216), FpS_ISDIR
(217), FPS_ISSOCK (218)
1.4.89 fpS_ISSOCK
Synopsis: Is file a Unix socket
Declaration: function fpS_ISSOCK(m: TMode) : Boolean
Visibility: default
Description: FpS_ISSOCK checks the file mode m to see whether the file is a socket. If so it returns True.
See also: FpFStat (182), FpS_ISFIFO (217), FpS_ISLNK (217), FpS_ISCHR (216), FpS_ISBLK (216), FpS_ISDIR
(217), FpS_ISREG (218)
1.4.90 fptime
Synopsis: Return the current Unix time
Declaration: function FpTime(var tloc: TTime) : TTime
function fptime : time_t
Visibility: default
Description: FpTime returns the number of seconds since 00:00:00 GMT, january 1, 1970. it is adjusted to the
local time zone, but not to DST. The result is also stored in tloc, if it is specified.
Errors: On error, -1 is returned. Extended error information can be retrieved using fpGetErrno (185).
Listing: ./bunixex/ex1.pp
218
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
Program Example1 ;
{ Program t o demonstrate t h e f p t i m e f u n c t i o n . }
Uses baseunix ;
begin
Write ( ’ Secs p a s t t h e s t a r t o f t h e Epoch ( 0 0 : 0 0 1 / 1 / 1 9 8 0 ) : ’ ) ;
Writeln ( fptime ) ;
end .
1.4.91 FpTimes
Synopsis: Return execution times for the current process
Declaration: function FpTimes(var buffer: tms) : TClock
Visibility: default
Description: fpTimes stores the execution time of the current process and child processes in buffer.
The return value (on Linux) is the number of clock ticks since boot time. On error, -1 is returned,
and extended error information can be retrieved with fpGetErrno (185).
See also: fpUTime (220)
1.4.92 FpUmask
Synopsis: Set file creation mask.
Declaration: function FpUmask(cmask: TMode) : TMode
Visibility: default
Description: fpUmask changes the file creation mask for the current user to cmask. The current mask is re-
turned.
See also: fpChmod (173)
Listing: ./bunixex/ex27.pp
Program Example27 ;
{ Program t o demonstrate t h e Umask f u n c t i o n . }
Uses BaseUnix ;
begin
W r i t e l n ( ’ Old Umask was : ’ , fpUmask ( & 1 1 1 ) ) ;
WRiteln ( ’New Umask i s : ’ ,&111);
end .
219
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
1.4.93 FpUname
Synopsis: Return system name.
Declaration: function FpUname(var name: UtsName) : cint
Visibility: default
Description: Uname gets the name and configuration of the current Linux kernel, and returns it in the name
record.
On success, 0 is returned, on error, -1 is returned.
Errors: Extended error information can be retrieved using fpGetErrno (185).
See also: FpUTime (220)
1.4.94 FpUnlink
Synopsis: Unlink (i.e. remove) a file.
Declaration: function FpUnlink(path: PChar) : cint
function FpUnlink(const path: RawByteString) : cint
Visibility: default
Description: FpUnlink decreases the link count on file Path. Path can be of type AnsiString or PChar.
If the link count is zero, the file is removed from the disk.
The function returns zero if the call was succesfull, a nonzero value indicates failure.
Note: There exist a portable alterative to erase files: system.erase. Please use fpUnlink only if you
are writing Unix specific code. System.erase will work on all operating systems.
For an example, see FpLink (190).
Errors: Extended error information can be retrieved using fpGetErrno (185).
sys_eaccessYou have no write access right in the directory containing Path, or you have no search
permission in one of the directory components of Path.
sys_epermThe directory containing pathname has the sticky-bit set and the process’s effective uid is
neither the uid of the file to be deleted nor that of the directory containing it.
sys_enoentA component of the path doesn’t exist.
sys_enotdirA directory component of the path is not a directory.
sys_eisdirPath refers to a directory.
sys_enomemInsufficient kernel memory.
sys_erofsPath is on a read-only filesystem.
See also: FpLink (190), FpSymLink (215)
1.4.95 FpUtime
Synopsis: Set access and modification times of a file (touch).
Declaration: function FpUtime(path: PChar; times: pUtimBuf) : cint
function FpUtime(const path: RawByteString; times: pUtimBuf) : cint
Visibility: default
220
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
Description: FpUtime sets the access and modification times of the file specified in Path. the times record
contains 2 fields, actime, and modtime, both of type time_t (commonly a longint). They
should be filled with an epoch-like time, specifying, respectively, the last access time, and the last
modification time. For some filesystem (most notably, FAT), these times are the same.
The function returns zero on success, a nonzero return value indicates failure.
Errors: Extended error information can be retrieved using fpGetErrno (185).
sys_eaccessOne of the directories in Path has no search (=execute) permission.
sys_enoentA directory entry in Path does not exist or is a symbolic link pointing to a non-existent
directory.
Other errors may occur, but aren’t documented.
See also: FpTime (218), FpChown (174), FpAccess (171)
Listing: ./bunixex/ex25.pp
Program Example25 ;
{ Program t o demonstrate t h e UTime f u n c t i o n . }
Uses Dos , BaseUnix , Unix , U n i x U t i l ;
Var u t i m : u t i m b u f ;
dow , msec , year , month , day , hour , minute , second : Word ;
begin
{ Set access and m o d i f i c a t i o n t i m e o f e x e c u t a b l e source }
GetTime ( hour , minute , second , msec ) ;
GetDate ( year , month , day , dow ) ;
u t i m . actime : = LocalToEpoch ( year , month , day , hour , minute , second ) ;
u t i m . modtime : = u t i m . actime ;
i f Fputime ( ’ ex25 . pp ’ , @utim) < >0 then
w r i t e l n ( ’ C a l l t o UTime f a i l e d ! ’ )
else
begin
Write ( ’ Set access and m o d i f i c a t i o n t i m e s t o : ’ ) ;
Write ( Hour : 2 , ’ : ’ , minute : 2 , ’ : ’ , second , ’ , ’ ) ;
W r i t e l n ( Day : 2 , ’ / ’ , month : 2 , ’ / ’ , year : 4 ) ;
end ;
end .
1.4.96 FpWait
Synopsis: Wait for a child to exit.
Declaration: function FpWait(var stat_loc: cint) : TPid
Visibility: default
Description: fpWait suspends the current process and waits for any child to exit or stop due to a signal. It
reports the exit status of the exited child in stat_loc.
The return value of the function is the process ID of the child that exited, or -1 on error.
Errors: Extended error information can be retrieved using fpgetErrno (185).
See also: fpFork (182), fpExecve (178), fpWaitPid (222)
221
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
1.4.97 FpWaitPid
Synopsis: Wait for a process to terminate
Declaration: function FpWaitpid(pid: TPid; stat_loc: pcint; options: cint) : TPid
function FpWaitPid(pid: TPid; var Status: cint; Options: cint) : TPid
Visibility: default
Description: fpWaitPid waits for a child process with process ID Pid to exit. The value of Pid can be one of
the following:
Pid < -1Causes fpWaitPid to wait for any child process whose process group ID equals the abso-
lute value of pid.
Pid = -1Causes fpWaitPid to wait for any child process.
Pid = 0Causes fpWaitPid to wait for any child process whose process group ID equals the one of
the calling process.
Pid > 0Causes fpWaitPid to wait for the child whose process ID equals the value of Pid.
The Options parameter can be used to specify further how fpWaitPid behaves:
WNOHANGCauses fpWaitpid to return immediately if no child hasexited.
WUNTRACEDCauses fpWaitPid to return also for children which are stopped, but whose status
has not yet been reported.
__WCLONECauses fpWaitPid also to wait for threads created by the #rtl.linux.Clone (929) call.
The exit status of the process that caused fpWaitPID is reported in stat_loc or Status.
Upon return, it returns the process id of the process that exited, 0 if no process exited, or -1 in case
of failure.
For an example, see fpFork (182).
Errors: Extended error information can be retrieved using fpgetErrno (185).
See also: fpFork (182), fpExecve (178), fpWait (221)
1.4.98 FpWrite
Synopsis: Write data to file descriptor
Declaration: function FpWrite(fd: cint; buf: PChar; nbytes: TSize) : TsSize
function FpWrite(fd: cint; const buf; nbytes: TSize) : TsSize
Visibility: default
Description: FpWrite writes at most nbytes bytes from buf to file descriptor fd.
The function returns the number of bytes actually written, or -1 if an error occurred.
Errors: Extended error information can be retrieved using fpGetErrno (185).
See also: FpOpen (197), FpClose (175), FpRead (201), FpFTruncate (183), FpLSeek (191)
222
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
1.4.99 FpWriteV
Synopsis: Vector write: Write from multiple buffers to a file descriptor
Declaration: function FpWriteV(fd: cint; const iov: piovec; iovcnt: cint) : TsSize
Visibility: default
Description: FpWriteV writes data to file descriptor fd. The data is taken from iovcnt buffers described by
the tiovec (166) buffers pointed to by iov. It works like fpWrite (222) only from multiple buffers.
Errors: On error, -1 is returned.
See also: FpReadV (204), FpPWrite (201), FpPRead (200)
1.4.100 FreeShellArgV
Synopsis: Free the result of a CreateShellArgV (170) function
Declaration: procedure FreeShellArgV(p: PPChar)
Visibility: default
Description: FreeShellArgV frees the memory pointed to by P, which was allocated by a call to CreateShel-
lArgV (170).
Errors: None.
See also: CreateShellArgV (170)
1.4.101 wexitStatus
Synopsis: Extract the exit status from the fpWaitPID (222) result.
Declaration: function wexitStatus(Status: cint) : cint
Visibility: default
Description: WEXITSTATUS can be used to extract the exit status from Status, the result of the FpWaitPID
(222) call.
See also: FpWaitPID (222), WTERMSIG (224), WSTOPSIG (224), WIFEXITED (223), WIFSIGNALED
(224)
1.4.102 wifexited
Synopsis: Check whether the process exited normally
Declaration: function wifexited(Status: cint) : Boolean
Visibility: default
Description: WIFEXITED checks Status and returns True if the status indicates that the process terminated
normally, i.e. was not stopped by a signal.
See also: FpWaitPID (222), WTERMSIG (224), WSTOPSIG (224), WIFSIGNALED (224), WEXITSTATUS
(223)
223
CHAPTER 1. REFERENCE FOR UNIT ’BASEUNIX’
1.4.103 wifsignaled
Synopsis: Check whether the process was exited by a signal.
Declaration: function wifsignaled(Status: cint) : Boolean
Visibility: default
Description: WIFSIGNALED returns True if Status indicates that the process exited because it received a
signal.
See also: FpWaitPID (222), WTERMSIG (224), WSTOPSIG (224), WIFEXITED (223), WEXITSTATUS
(223)
1.4.104 wstopsig
Synopsis: Return the exit code from the process.
Declaration: function wstopsig(Status: cint) : cint
Visibility: default
Description: WSTOPSIG is an alias for WEXITSTATUS (223).
See also: FpWaitPID (222), WTERMSIG (224), WIFEXITED (223), WIFSIGNALED (224), WEXITSTA-
TUS (223)
1.4.105 wtermsig
Synopsis: Return the signal that caused a process to exit.
Declaration: function wtermsig(Status: cint) : cint
Visibility: default
Description: WTERMSIG extracts from Status the signal number which caused the process to exit.
See also: FpWaitPID (222), WSTOPSIG (224), WIFEXITED (223), WIFSIGNALED (224), WEXITSTATUS
(223)
224
Chapter 2
Reference for unit ’character’
2.1 Used units
Table 2.1: Used units by unit ’character’
Name Page
System 1280
unicodedata 1894
2.2 Overview
The character unit contains the TCharacter (233) class, which consists mainly of class functions. It
should not be constructed, but its class methods can be used. All class methods also exist as regular
methods.
Many routines depend on unicode collation data to be present in the binary (or distributed on disc
with the application. This data can be loaded using the routines in the unicodedata (1894) unit.. The
FPC project distributes some unicode collation data in .bco files which can be loaded using the
LoadCollation (1903) routine from that unit.
2.3 Constants, types and variables
2.3.1 Types
TCharacterOption = (coIgnoreInvalidSequence)
Table 2.2: Enumeration values for type TCharacterOption
Value Explanation
coIgnoreInvalidSequence Ignore invalid unicodecode sequences
TCharacterOption is used in the toUpper (233) and toLower (232) functions to control the
behaviour of the function.
225
CHAPTER 2. REFERENCE FOR UNIT ’CHARACTER’
TCharacterOptions = Set of TCharacterOption
TCharacterOptions is the set of TCharacterOption, used in toUpper (233) and toLower
(232) functions to control the behaviour of the function.
TUnicodeCategory = (ucUppercaseLetter,ucLowercaseLetter,
ucTitlecaseLetter,ucModifierLetter,ucOtherLetter,
ucNonSpacingMark,ucCombiningMark,ucEnclosingMark
,
ucDecimalNumber,ucLetterNumber,ucOtherNumber
,
ucConnectPunctuation,ucDashPunctuation,
ucOpenPunctuation,ucClosePunctuation,
ucInitialPunctuation,ucFinalPunctuation,
ucOtherPunctuation,ucMathSymbol,ucCurrencySymbol,
ucModifierSymbol,ucOtherSymbol,ucSpaceSeparator,
ucLineSeparator,ucParagraphSeparator,ucControl,
ucFormat,ucSurrogate,ucPrivateUse,ucUnassigned)
226
CHAPTER 2. REFERENCE FOR UNIT ’CHARACTER’
Table 2.3: Enumeration values for type TUnicodeCategory
Value Explanation
ucClosePunctuation Punctuation, close (Pe)
ucCombiningMark Mark, spacing combining (Mc)
ucConnectPunctuation Punctuation, connector (Pc)
ucControl Other, control (Cc)
ucCurrencySymbol Symbol, currency (Sc)
ucDashPunctuation Punctuation, dash (Pd)
ucDecimalNumber Number, decimal digit (Nd)
ucEnclosingMark Mark, enclosing (Me)
ucFinalPunctuation Punctuation, final quote (Pf, may behave like Ps or Pe depending on usage)
ucFormat Other, format (Cf)
ucInitialPunctuation Punctuation, initial quote (Pi, may behave like Ps or Pe depending on usage)
ucLetterNumber Number, letter (Nl)
ucLineSeparator Separator, line (Zl)
ucLowercaseLetter Letter, lowercase (Ll)
ucMathSymbol Symbol, math (Sm)
ucModifierLetter Letter, modifier (Lm)
ucModifierSymbol Symbol, modifier (Sk)
ucNonSpacingMark Mark, nonspacing (Mn)
ucOpenPunctuation Punctuation, open (Ps)
ucOtherLetter Letter, other (Lo)
ucOtherNumber Number, other (No)
ucOtherPunctuation Punctuation, other (Po)
ucOtherSymbol Symbol, other (So)
ucParagraphSeparator Separator, paragraph (Zp)
ucPrivateUse Other, private use (Co)
ucSpaceSeparator Separator, space (Zs)
ucSurrogate Other, surrogate (Cs)
ucTitlecaseLetter Letter, titlecase (Lt)
ucUnassigned Other, not assigned (including noncharacters) (Cn)
ucUppercaseLetter Letter, uppercase (Lu)
This enumeration type contains the characterization of all possible unicode characters. It is used in
the GetUnicodeCategory (228) and TCharacter.GetUnicodeCategory (235) functions.
TUnicodeCategorySet = Set of TUnicodeCategory
TUnicodeCategorySet is the set of TUnicodeCategory (226). It is used internally in the TChar-
acter (233) class.
2.4 Procedures and functions
2.4.1 ConvertFromUtf32
Synopsis: alias for TCharacter.ConvertFromUtf32
Declaration: function ConvertFromUtf32(AChar: UCS4Char) : UnicodeString
Visibility: default
227
CHAPTER 2. REFERENCE FOR UNIT ’CHARACTER’
Description: ConvertFromUtf32 is a shortcut for TCharacter.ConvertFromUtf32 (234).
See also: TCharacter.ConvertFromUtf32 (234)
2.4.2 ConvertToUtf32
Synopsis: alias for TCharacter.ConvertToUtf32
Declaration: function ConvertToUtf32(const AString: UnicodeString; AIndex: Integer)
: UCS4Char; Overload
function ConvertToUtf32(const AString: UnicodeString; AIndex: Integer;
out ACharLength: Integer) : UCS4Char; Overload
function ConvertToUtf32(const AHighSurrogate: UnicodeChar;
const ALowSurrogate: UnicodeChar) : UCS4Char
; Overload
Visibility: default
Description: ConvertToUtf32 is a shortcut for TCharacter.ConvertToUtf32 (234).
See also: TCharacter.ConvertToUtf32 (234)
2.4.3 GetNumericValue
Synopsis: Alias for TCharacter.GetNumericValue
Declaration: function GetNumericValue(AChar: UnicodeChar) : Double; Overload
function GetNumericValue(const AString: UnicodeString; AIndex: Integer)
: Double; Overload
Visibility: default
Description: GetNumericValue is a shortcut for TCharacter.GetNumericValue (235).
See also: TCharacter.GetNumericValue (235)
2.4.4 GetUnicodeCategory
Synopsis: Alias for TCharacter.GetUnicodeCategory
Declaration: function GetUnicodeCategory(AChar: UnicodeChar) : TUnicodeCategory
; Overload
function GetUnicodeCategory(const AString: UnicodeString;
AIndex: Integer) : TUnicodeCategory
; Overload
Visibility: default
Description: GetUnicodeCategory is a shortcut for TCharacter.GetUnicodeCategory (235).
See also: TCharacter.GetUnicodeCategory (235)
228
CHAPTER 2. REFERENCE FOR UNIT ’CHARACTER’
2.4.5 IsControl
Synopsis: Alias for TCharacter.IsControl
Declaration: function IsControl(AChar: UnicodeChar) : Boolean; Overload
function IsControl(const AString: UnicodeString; AIndex: Integer)
: Boolean; Overload
Visibility: default
Description: IsControl is a shortcut for TCharacter.IsControl (235).
See also: TCharacter.IsControl (235)
2.4.6 IsDigit
Synopsis: Alias for TCharacter.IsDigit
Declaration: function IsDigit(AChar: UnicodeChar) : Boolean; Overload
function IsDigit(const AString: UnicodeString; AIndex: Integer)
: Boolean; Overload
Visibility: default
Description: IsDigit is a shortcut for TCharacter.IsDigit (236).
See also: TCharacter.IsDigit (236)
2.4.7 IsHighSurrogate
Synopsis: Alias for TCharacter.IsHighSurrogate
Declaration: function IsHighSurrogate(AChar: UnicodeChar) : Boolean; Overload
function IsHighSurrogate(const AString: UnicodeString; AIndex: Integer)
: Boolean; Overload
Visibility: default
Description: IsHighSurrogate is a shortcut for TCharacter.IsHighSurrogate (237)
See also: TCharacter.IsHighSurrogate (237)
2.4.8 IsLetter
Synopsis: Alias for TCharacter.IsLetter
Declaration: function IsLetter(AChar: UnicodeChar) : Boolean; Overload
function IsLetter(const AString: UnicodeString; AIndex: Integer)
: Boolean; Overload
Visibility: default
Description: IsLetter is a shortcut for TCharacter.IsLetter (238)
See also: TCharacter.IsLetter (238)
229
CHAPTER 2. REFERENCE FOR UNIT ’CHARACTER’
2.4.9 IsLetterOrDigit
Synopsis: Alias for TCharacter.IsLetterOrDigit
Declaration: function IsLetterOrDigit(AChar: UnicodeChar) : Boolean; Overload
function IsLetterOrDigit(const AString: UnicodeString; AIndex: Integer)
: Boolean; Overload
Visibility: default
Description: IsLetterOrDigit is a shortcut for TCharacter.IsLetterOrDigit (238).
See also: TCharacter.IsLetterOrDigit (238)
2.4.10 IsLower
Synopsis: Alias for TCharacter.IsLower
Declaration: function IsLower(AChar: UnicodeChar) : Boolean; Overload
function IsLower(const AString: UnicodeString; AIndex: Integer)
: Boolean; Overload
Visibility: default
Description: IsLower is a shortcut for TCharacter.IsLower (239)
See also: TCharacter.IsLower (239)
2.4.11 IsLowSurrogate
Synopsis: Alias for TCharacter.IsLowSurrogate
Declaration: function IsLowSurrogate(AChar: UnicodeChar) : Boolean; Overload
function IsLowSurrogate(const AString: UnicodeString; AIndex: Integer)
: Boolean; Overload
Visibility: default
Description: IsLowSurrogate is a shortcut for TCharacter.IsLowSurrogate (237)
See also: TCharacter.IsLowSurrogate (237)
2.4.12 IsNumber
Synopsis: Alias for TCharacter.IsNumber
Declaration: function IsNumber(AChar: UnicodeChar) : Boolean; Overload
function IsNumber(const AString: UnicodeString; AIndex: Integer)
: Boolean; Overload
Visibility: default
Description: IsNumber is a shortcut for TCharacter.IsNumber (239)
See also: TCharacter.IsNumber (239)
230
CHAPTER 2. REFERENCE FOR UNIT ’CHARACTER’
2.4.13 IsPunctuation
Synopsis: Alias for TCharacter.IsPunctuation
Declaration: function IsPunctuation(AChar: UnicodeChar) : Boolean; Overload
function IsPunctuation(const AString: UnicodeString; AIndex: Integer)
: Boolean; Overload
Visibility: default
Description: IsPunctuation is a shortcut for TCharacter.IsPunctuation (240)
See also: TCharacter.IsPunctuation (240)
2.4.14 IsSeparator
Synopsis: Alias for TCharacter.IsSeparator
Declaration: function IsSeparator(AChar: UnicodeChar) : Boolean; Overload
function IsSeparator(const AString: UnicodeString; AIndex: Integer)
: Boolean; Overload
Visibility: default
Description: IsSeparator is a shortcut for TCharacter.IsSeparator (240)
See also: TCharacter.IsSeparator (240)
2.4.15 IsSurrogate
Synopsis: Alias for TCharacter.IsSurrogate
Declaration: function IsSurrogate(AChar: UnicodeChar) : Boolean; Overload
function IsSurrogate(const AString: UnicodeString; AIndex: Integer)
: Boolean; Overload
Visibility: default
Description: IsSurrogate is a shortcut for TCharacter.IsSurrogate (236).
See also: TCharacter.IsSurrogate (236)
2.4.16 IsSurrogatePair
Synopsis: Alias for TCharacter.IsSurrogatePair
Declaration: function IsSurrogatePair(const AHighSurrogate: UnicodeChar;
const ALowSurrogate: UnicodeChar) : Boolean
; Overload
function IsSurrogatePair(const AString: UnicodeString; AIndex: Integer)
: Boolean; Overload
Visibility: default
Description: IsSurrogatePair is a shortcut for TCharacter.IsSurrogatePair (237)
See also: TCharacter.IsSurrogatePair (237)
231
CHAPTER 2. REFERENCE FOR UNIT ’CHARACTER’
2.4.17 IsSymbol
Synopsis: Alias for TCharacter.IsSymbol
Declaration: function IsSymbol(AChar: UnicodeChar) : Boolean; Overload
function IsSymbol(const AString: UnicodeString; AIndex: Integer)
: Boolean; Overload
Visibility: default
Description: IsSymbol is a shortcut for TCharacter.IsSymbol (240)
See also: TCharacter.IsSymbol (240)
2.4.18 IsUpper
Synopsis: Alias for TCharacter.IsUpper
Declaration: function IsUpper(AChar: UnicodeChar) : Boolean; Overload
function IsUpper(const AString: UnicodeString; AIndex: Integer)
: Boolean; Overload
Visibility: default
Description: IsUpper is a shortcut for TCharacter.IsUpper (241)
See also: TCharacter.IsUpper (241)
2.4.19 IsWhiteSpace
Synopsis: Alias for TCharacter.IsWhiteSpace
Declaration: function IsWhiteSpace(AChar: UnicodeChar) : Boolean; Overload
function IsWhiteSpace(const AString: UnicodeString; AIndex: Integer)
: Boolean; Overload
Visibility: default
Description: IsWhiteSpace is a shortcut for TCharacter.IsWhiteSpace (241)
See also: TCharacter.IsWhiteSpace (241)
2.4.20 ToLower
Synopsis: Alias for TCharacter.ToLower
Declaration: function ToLower(AChar: UnicodeChar) : UnicodeChar; Overload
function ToLower(const AString: UnicodeString) : UnicodeString
; Overload
Visibility: default
Description: ToLower is a shortcut for TCharacter.ToLower (242)
See also: TCharacter.ToLower (242)
232
CHAPTER 2. REFERENCE FOR UNIT ’CHARACTER’
2.4.21 ToUpper
Synopsis: Alias for TCharacter.ToUpper
Declaration: function ToUpper(AChar: UnicodeChar) : UnicodeChar; Overload
function ToUpper(const AString: UnicodeString) : UnicodeString
; Overload
Visibility: default
Description: ToUpper is a shortcut for TCharacter.ToUpper (242)
See also: TCharacter.ToUpper (242)
2.5 TCharacter
2.5.1 Description
TCharacter is provided for Delphi compatibility. All it’s class functions and methods are also
available as regular functions.
2.5.2 Method overview
Page Method Description
234 ConvertFromUtf32 Convert a UTF32 character to UnicodeString
234 ConvertToUtf32 Convert a UTF16 character to a UTF32 character
233 Create Constructor (do not call)
235 GetNumericValue Get the numeric value of the character
235 GetUnicodeCategory Get the unicode category of a character
235 IsControl Check whether a unicode character is a unicode control character
236 IsDigit Check whether a unicode character is a digit
237 IsHighSurrogate Check whether a unicode character is a surrogate in the high range
238 IsLetter Check if a unicode character is a letter.
238 IsLetterOrDigit Check if a unicode character is a letter or digit
239 IsLower Check if a unicode character is a lowercase letter
237 IsLowSurrogate Check whether a unicode character is a surrogate in the low range
239 IsNumber Check if a unicode character is a number
240 IsPunctuation Check if a unicode character is a punctuation character
240 IsSeparator Check if a unicode character is a separator character
236 IsSurrogate Check whether a unicode character is a surrogate
237 IsSurrogatePair Check if a pair of characters is a set of high/low surrorgate char-
acters
240 IsSymbol Check if a unicode character is a symbol character
241 IsUpper Check whether a unicode character is an uppercase letter
241 IsWhiteSpace Check whether a unicode character is a whitespace character
242 ToLower Convert a character or string to lowercase
242 ToUpper Convert a character or string to uppercase
2.5.3 TCharacter.Create
Synopsis: Constructor (do not call)
Declaration: constructor Create
Visibility: public
233
CHAPTER 2. REFERENCE FOR UNIT ’CHARACTER’
Description: Create is provided for completeness and Delphi compatibility, but should not be called in FPC
code, it will raise an exception.
Errors: Any attempt to call Create will result in an exception being raised.
2.5.4 TCharacter.ConvertFromUtf32
Synopsis: Convert a UTF32 character to UnicodeString
Declaration: class function ConvertFromUtf32(AChar: UCS4Char) : UnicodeString
; Static
Visibility: public
Description: TCharacter.ConvertFromUtf32 converts a single UTF32 character AChar to a UTF16
string. This is the opposite of TCharacter.ConvertToUtf32 (234).
The result is a string, since multiple UTF16 characters can be needed to encode a single UTF32
character.
Errors: If AChar is not in the valid range of UTF32 characters, an EArgumentOutOfRangeException (225)
exception is raised.
See also: EArgumentOutOfRangeException (225), TCharacter.ConvertToUtf32 (234)
2.5.5 TCharacter.ConvertToUtf32
Synopsis: Convert a UTF16 character to a UTF32 character
Declaration: class function ConvertToUtf32(const AString: UnicodeString;
AIndex: Integer) : UCS4Char; Overload
; Static
class function ConvertToUtf32(const AString: UnicodeString;
AIndex: Integer; out ACharLength: Integer)
: UCS4Char; Overload; Static
class function ConvertToUtf32(const AHighSurrogate: UnicodeChar;
const ALowSurrogate: UnicodeChar)
: UCS4Char; Overload; Static
Visibility: public
Description: TCharacter.ConvertToUtf32 converts a UTF16-encoded unicode character to a Unicode32
character. This is the opposite of TCharacter.ConvertFromUtf32 (234). The function exists in several
overloaded versions, to be able to present the unicode character in one of 2 ways:
1.As a position AIndex (in unicodechar units) in a string AString to a Unicode32 charac-
ter. The source is a string, since multiple UTF16 characters can be needed to encode a single
UTF32 character. In this form, Optionally, the character length (1 or 2) can be returned in
ACharLength.
2.As 2 UTF16 unicode characters, representing the high and low surrogate pairs: AHighSurrogate
and ALowSurrogate.
Errors: If AIndex is not a valid character index in the string AString, an EArgumentOutOfRangeExcep-
tion (225) exception is raised. If the character at that position is not complete, an EArgumentExcep-
tion (225) exception is raised.
See also: TCharacter.ConvertFromUtf32 (234), EArgumentOutOfRangeException (225), EArgumentExcep-
tion (225)
234
CHAPTER 2. REFERENCE FOR UNIT ’CHARACTER’
2.5.6 TCharacter.GetNumericValue
Synopsis: Get the numeric value of the character
Declaration: class function GetNumericValue(AChar: UnicodeChar) : Double; Overload
; Static
class function GetNumericValue(const AString: UnicodeString;
AIndex: Integer) : Double; Overload
; Static
Visibility: public
Description: TCharacter.GetNumericValue returns the numerical value (ID) of the unicode character.
The character can be presented in 2 ways: AChar, a UTF16 unicode character, or a surrogate pair in
a unicode string AString starting at position AIndex.
Errors: If AIndex is not a valid character index in the string AString, an EArgumentOutOfRangeExcep-
tion (225) exception is raised. If the character at that position is not complete, an EArgumentExcep-
tion (225) exception is raised.
See also: TCharacter.GetUnicodeCategory (235)
2.5.7 TCharacter.GetUnicodeCategory
Synopsis: Get the unicode category of a character
Declaration: class function GetUnicodeCategory(AChar: UnicodeChar) : TUnicodeCategory
; Overload; Static
class function GetUnicodeCategory(const AString: UnicodeString;
AIndex: Integer) : TUnicodeCategory
; Overload; Static
Visibility: public
Description: TCharacter.GetUnicodeCategory returns the unicode category of a character. The charac-
ter can be presented in 2 ways: AChar, a UTF16 unicode character, or a surrogate pair in a unicode
string AString starting at position AIndex.
Errors: If AIndex is not a valid character index in the string AString, an EArgumentOutOfRangeExcep-
tion (225) exception is raised. If the character at that position is not complete, an EArgumentExcep-
tion (225) exception is raised.
See also: TUnicodeCategory (226)
2.5.8 TCharacter.IsControl
Synopsis: Check whether a unicode character is a unicode control character
Declaration: class function IsControl(AChar: UnicodeChar) : Boolean; Overload
; Static
class function IsControl(const AString: UnicodeString; AIndex: Integer)
: Boolean; Overload; Static
Visibility: public
Description: IsControl returns True if a unicode character has category ucControl. The character can be
specified as a UTF16 character AChar or a UTF16 encoded character starting at position AIndex
in string AString.
235
CHAPTER 2. REFERENCE FOR UNIT ’CHARACTER’
Errors: If AIndex is not a valid character index in the string AString, an EArgumentOutOfRangeExcep-
tion (225) exception is raised. If the character at that position is not complete, an EArgumentExcep-
tion (225) exception is raised.
See also: GetUnicodeCategory (235), IsDigit (236), IsSurrogate (236), IsHighSurrogate (237), IsLowSurro-
gate (237), IsSurrogatePair (237), IsLetter (238), IsLetterOrDigit (238), IsLower (239), IsNumber
(239), IsPunctuation (240), IsSeparator (240), IsSymbol (240), IsUpper (241), IsWhiteSpace (241)
2.5.9 TCharacter.IsDigit
Synopsis: Check whether a unicode character is a digit
Declaration: class function IsDigit(AChar: UnicodeChar) : Boolean; Overload; Static
class function IsDigit(const AString: UnicodeString; AIndex: Integer)
: Boolean; Overload; Static
Visibility: public
Description: IsDigit returns True if a unicode character has category ucDecimalNumber. The character
can be specified as a UTF16 character AChar or a UTF16 encoded character starting at position
AIndex in string AString.
Errors: If AIndex is not a valid character index in the string AString, an EArgumentOutOfRangeExcep-
tion (225) exception is raised. If the character at that position is not complete, an EArgumentExcep-
tion (225) exception is raised.
See also: IsControl (235), IsDigit (236), IsSurrogate (236), IsHighSurrogate (237), IsLowSurrogate (237), Is-
SurrogatePair (237), IsLetter (238), IsLetterOrDigit (238), IsLower (239), IsNumber (239), IsPunc-
tuation (240), IsSeparator (240), IsSymbol (240), IsUpper (241), IsWhiteSpace (241)
2.5.10 TCharacter.IsSurrogate
Synopsis: Check whether a unicode character is a surrogate
Declaration: class function IsSurrogate(AChar: UnicodeChar) : Boolean; Overload
; Static
class function IsSurrogate(const AString: UnicodeString;
AIndex: Integer) : Boolean; Overload; Static
Visibility: public
Description: IsSurrogate returns True if a unicode character has category ucSurrogate. The character
can be specified as a UTF16 character AChar or a UTF16 encoded character starting at position
AIndex in string AString.
Errors: If AIndex is not a valid character index in the string AString, an EArgumentOutOfRangeExcep-
tion (225) exception is raised. If the character at that position is not complete, an EArgumentExcep-
tion (225) exception is raised.
See also: EArgumentException (225), IsControl (235), IsDigit (236), IsHighSurrogate (237), IsLowSurrogate
(237), IsLetter (238), IsLetterOrDigit (238), IsLower (239), IsNumber (239), IsPunctuation (240),
IsSymbol (240), IsUpper (241), IsWhiteSpace (241)
236
CHAPTER 2. REFERENCE FOR UNIT ’CHARACTER’
2.5.11 TCharacter.IsHighSurrogate
Synopsis: Check whether a unicode character is a surrogate in the high range
Declaration: class function IsHighSurrogate(AChar: UnicodeChar) : Boolean; Overload
; Static
class function IsHighSurrogate(const AString: UnicodeString;
AIndex: Integer) : Boolean; Overload
; Static
Visibility: public
Description: IsHighSurrogate returns True if a unicode character has category ucSurrogate and is in
the high range of the surrogate characters (between HIGH_SURROGATE_BEGIN and HIGH_SURROGATE_END).
The character can be specified as a UTF16 character AChar or a UTF16 encoded character starting
at position AIndex in string AString.
Errors: If AIndex is not a valid character index in the string AString, an EArgumentOutOfRangeExcep-
tion (225) exception is raised. If the character at that position is not complete, an EArgumentExcep-
tion (225) exception is raised.
See also: EArgumentException (225), IsControl (235), IsDigit (236), IsSurrogate (236), IsLowSurrogate (237),
IsLetter (238), IsLetterOrDigit (238), IsLower (239), IsNumber (239), IsPunctuation (240), IsSym-
bol (240), IsUpper (241), IsWhiteSpace (241)
2.5.12 TCharacter.IsLowSurrogate
Synopsis: Check whether a unicode character is a surrogate in the low range
Declaration: class function IsLowSurrogate(AChar: UnicodeChar) : Boolean; Overload
; Static
class function IsLowSurrogate(const AString: UnicodeString;
AIndex: Integer) : Boolean; Overload
; Static
Visibility: public
Description: IsLowSurrogate returns True if a unicode character has category ucSurrogate and is in the
low range of the surrogate characters (between LOW_SURROGATE_BEGIN and LOW_SURROGATE_END).
The character can be specified as a UTF16 character AChar or a UTF16 encoded character starting
at position AIndex in string AString.
Errors: If AIndex is not a valid character index in the string AString, an EArgumentOutOfRangeExcep-
tion (225) exception is raised. If the character at that position is not complete, an EArgumentExcep-
tion (225) exception is raised.
See also: EArgumentException (225), IsControl (235), IsDigit (236), IsSurrogate (236), IsHighSurrogate
(237), IsLetter (238), IsLetterOrDigit (238), IsLower (239), IsNumber (239), IsPunctuation (240),
IsSymbol (240), IsUpper (241), IsWhiteSpace (241)
2.5.13 TCharacter.IsSurrogatePair
Synopsis: Check if a pair of characters is a set of high/low surrorgate characters
Declaration: class function IsSurrogatePair(const AHighSurrogate: UnicodeChar;
const ALowSurrogate: UnicodeChar)
: Boolean; Overload; Static
237
CHAPTER 2. REFERENCE FOR UNIT ’CHARACTER’
class function IsSurrogatePair(const AString: UnicodeString;
AIndex: Integer) : Boolean; Overload
; Static
Visibility: public
Description: IsSurrogatePair returns True if AHighSurrogate and ALowSurrogate form a valid
unicode surrogate pair. (AHighSurrogate is a high surrogate and ALowSurrogate a matching
low surrogate) The character can be specified as a UTF16 character AChar or a pair of UTF16
encoded characters starting at position AIndex in string AString.
Errors: If AIndex is not a valid character index in the string AString, an EArgumentOutOfRangeExcep-
tion (225) exception is raised. If the character at that position is not complete, an EArgumentExcep-
tion (225) exception is raised.
See also: EArgumentException (225), IsControl (235), IsDigit (236), IsSurrogate (236), IsHighSurrogate
(237), IsLowSurrogate (237), IsLetter (238), IsLetterOrDigit (238), IsLower (239), IsNumber (239),
IsPunctuation (240), IsSymbol (240), IsUpper (241), IsWhiteSpace (241)
2.5.14 TCharacter.IsLetter
Synopsis: Check if a unicode character is a letter.
Declaration: class function IsLetter(AChar: UnicodeChar) : Boolean; Overload
; Static
class function IsLetter(const AString: UnicodeString; AIndex: Integer)
: Boolean; Overload; Static
Visibility: public
Description: IsLetter returns True if a unicode character has category that is one of the letter categories
(ucUppercaseLetter, ucLowercaseLetter, ucTitlecaseLetter, ucModifierLetter,
ucOtherLetter). The character can be specified as a UTF16 character AChar or a UTF16 en-
coded character starting at position AIndex in string AString.
Errors: If AIndex is not a valid character index in the string AString, an EArgumentOutOfRangeExcep-
tion (225) exception is raised. If the character at that position is not complete, an
See also: EArgumentException (225), IsControl (235), IsDigit (236), IsSurrogate (236), IsHighSurrogate
(237), IsLowSurrogate (237), IsSurrogatePair (237), IsLetter (238), IsLetterOrDigit (238), IsLower
(239), IsNumber (239), IsPunctuation (240), IsSymbol (240), IsUpper (241), IsWhiteSpace (241)
2.5.15 TCharacter.IsLetterOrDigit
Synopsis: Check if a unicode character is a letter or digit
Declaration: class function IsLetterOrDigit(AChar: UnicodeChar) : Boolean; Overload
; Static
class function IsLetterOrDigit(const AString: UnicodeString;
AIndex: Integer) : Boolean; Overload
; Static
Visibility: public
Description: IsLetterOrDigit returns True if a unicode character has category that is one of the letter cate-
gories (ucUppercaseLetter, ucLowercaseLetter, ucTitlecaseLetter, ucModifierLetter,
ucOtherLetter,ucDecimalNumber,ucLetterNumber). The character can be specified as
238
CHAPTER 2. REFERENCE FOR UNIT ’CHARACTER’
a UTF16 character AChar or a UTF16 encoded character starting at position AIndex in string
AString.
Errors: If AIndex is not a valid character index in the string AString, an EArgumentOutOfRangeExcep-
tion (225) exception is raised. If the character at that position is not complete, an EArgumentExcep-
tion (225) exception is raised.
See also: IsControl (235), IsDigit (236), IsSurrogate (236), IsHighSurrogate (237), IsLowSurrogate (237),
IsSurrogatePair (237), IsLetter (238), IsLower (239), IsNumber (239), IsPunctuation (240), IsSymbol
(240), IsUpper (241), IsWhiteSpace (241)
2.5.16 TCharacter.IsLower
Synopsis: Check if a unicode character is a lowercase letter
Declaration: class function IsLower(AChar: UnicodeChar) : Boolean; Overload; Static
class function IsLower(const AString: UnicodeString; AIndex: Integer)
: Boolean; Overload; Static
Visibility: public
Description: IsLower returns True if a unicode character has category ucLowercaseLetter. The charac-
ter can be specified as a UTF16 character AChar or a UTF16 encoded character starting at position
AIndex in string AString.
Errors: If AIndex is not a valid character index in the string AString, an EArgumentOutOfRangeExcep-
tion (225) exception is raised. If the character at that position is not complete, an EArgumentExcep-
tion (225) exception is raised.
See also: IsControl (235), IsDigit (236), IsSurrogate (236), IsHighSurrogate (237), IsLowSurrogate (237),
IsSurrogatePair (237), IsLetter (238), IsLetterOrDigit (238), IsNumber (239), IsPunctuation (240),
IsSymbol (240), IsUpper (241), IsWhiteSpace (241)
2.5.17 TCharacter.IsNumber
Synopsis: Check if a unicode character is a number
Declaration: class function IsNumber(AChar: UnicodeChar) : Boolean; Overload
; Static
class function IsNumber(const AString: UnicodeString; AIndex: Integer)
: Boolean; Overload; Static
Visibility: public
Description: IsNumber returns True if a unicode character has category that is one of the number categories
(ucDecimalNumber, ucLetterNumber, ucOtherNumber). The character can be specified
as a UTF16 character AChar or a UTF16 encoded character starting at position AIndex in string
AString.
Errors: If AIndex is not a valid character index in the string AString, an EArgumentOutOfRangeExcep-
tion (225) exception is raised. If the character at that position is not complete, an EArgumentExcep-
tion (225) exception is raised.
See also: IsControl (235), IsDigit (236), IsSurrogate (236), IsHighSurrogate (237), IsLowSurrogate (237), Is-
SurrogatePair (237), IsLetter (238), IsLetterOrDigit (238), IsLower (239), IsNumber (239), IsPunc-
tuation (240), IsSymbol (240), IsUpper (241), IsWhiteSpace (241)
239
CHAPTER 2. REFERENCE FOR UNIT ’CHARACTER’
2.5.18 TCharacter.IsPunctuation
Synopsis: Check if a unicode character is a punctuation character
Declaration: class function IsPunctuation(AChar: UnicodeChar) : Boolean; Overload
; Static
class function IsPunctuation(const AString: UnicodeString;
AIndex: Integer) : Boolean; Overload
; Static
Visibility: public
Description: IsPunctuation returns True if a unicode character has category that is one of the punctua-
tion categories (ucConnectPunctuation, ucDashPunctuation, ucOpenPunctuation,
ucClosePunctuation, ucInitialPunctuation, ucFinalPunctuation, ucOtherPunctuation).
The character can be specified as a UTF16 character AChar or a UTF16 encoded character starting
at position AIndex in string AString.
Errors: If AIndex is not a valid character index in the string AString, an EArgumentOutOfRangeExcep-
tion (225) exception is raised. If the character at that position is not complete, an EArgumentExcep-
tion (225) exception is raised.
See also: IsControl (235), IsDigit (236), IsSurrogate (236), IsHighSurrogate (237), IsLowSurrogate (237), Is-
SurrogatePair (237), IsLetter (238), IsLetterOrDigit (238), IsLower (239), IsNumber (239), IsSymbol
(240), IsUpper (241), IsWhiteSpace (241)
2.5.19 TCharacter.IsSeparator
Synopsis: Check if a unicode character is a separator character
Declaration: class function IsSeparator(AChar: UnicodeChar) : Boolean; Overload
; Static
class function IsSeparator(const AString: UnicodeString;
AIndex: Integer) : Boolean; Overload; Static
Visibility: public
Description: IsSeparator returns True if a unicode character has category that is one of the separator cat-
egories (ucSpaceSeparator, ucLineSeparator, ucParagraphSeparator). The char-
acter can be specified as a UTF16 character AChar or a UTF16 encoded character starting at position
AIndex in string AString.
Errors: If AIndex is not a valid character index in the string AString, an EArgumentOutOfRangeExcep-
tion (225) exception is raised. If the character at that position is not complete, an EArgumentExcep-
tion (225) exception is raised.
See also: IsControl (235), IsDigit (236), IsSurrogate (236), IsHighSurrogate (237), IsLowSurrogate (237), Is-
SurrogatePair (237), IsLetter (238), IsLetterOrDigit (238), IsLower (239), IsNumber (239), IsPunc-
tuation (240), IsSymbol (240), IsUpper (241), IsWhiteSpace (241)
2.5.20 TCharacter.IsSymbol
Synopsis: Check if a unicode character is a symbol character
Declaration: class function IsSymbol(AChar: UnicodeChar) : Boolean; Overload
; Static
class function IsSymbol(const AString: UnicodeString; AIndex: Integer)
: Boolean; Overload; Static
240
CHAPTER 2. REFERENCE FOR UNIT ’CHARACTER’
Visibility: public
Description: IsSymbol returns True if a unicode character has category that is one of the symbol categories
(ucMathSymbol, ucCurrencySymbol, ucModifierSymbol, ucOtherSymbol). The char-
acter can be specified as a UTF16 character AChar or a UTF16 encoded character starting at position
AIndex in string AString.
Errors: If AIndex is not a valid character index in the string AString, an EArgumentOutOfRangeExcep-
tion (225) exception is raised. If the character at that position is not complete, an EArgumentExcep-
tion (225) exception is raised.
See also: IsControl (235), IsDigit (236), IsSurrogate (236), IsHighSurrogate (237), IsLowSurrogate (237), Is-
SurrogatePair (237), IsLetter (238), IsLetterOrDigit (238), IsLower (239), IsNumber (239), IsPunc-
tuation (240), IsSeparator (240), IsUpper (241), IsWhiteSpace (241)
2.5.21 TCharacter.IsUpper
Synopsis: Check whether a unicode character is an uppercase letter
Declaration: class function IsUpper(AChar: UnicodeChar) : Boolean; Overload; Static
class function IsUpper(const AString: UnicodeString; AIndex: Integer)
: Boolean; Overload; Static
Visibility: public
Description: IsUpper returns True if a unicode character has category ucUppercaseLetter. The charac-
ter can be specified as a UTF16 character AChar or a UTF16 encoded character starting at position
AIndex in string AString.
Errors: If AIndex is not a valid character index in the string AString, an EArgumentOutOfRangeExcep-
tion (225) exception is raised. If the character at that position is not complete, an EArgumentExcep-
tion (225) exception is raised.
See also: IsControl (235), IsDigit (236), IsSurrogate (236), IsHighSurrogate (237), IsLowSurrogate (237), Is-
SurrogatePair (237), IsLetter (238), IsLetterOrDigit (238), IsLower (239), IsNumber (239), IsPunc-
tuation (240), IsSeparator (240), IsSymbol (240), IsWhiteSpace (241)
2.5.22 TCharacter.IsWhiteSpace
Synopsis: Check whether a unicode character is a whitespace character
Declaration: class function IsWhiteSpace(AChar: UnicodeChar) : Boolean; Overload
; Static
class function IsWhiteSpace(const AString: UnicodeString;
AIndex: Integer) : Boolean; Overload
; Static
Visibility: public
Description: IsUpper returns True if a unicode character has is a whitespace character. It checks the char-
acter properties. The character can be specified as a UTF16 character AChar or a UTF16 encoded
character starting at position AIndex in string AString.
Errors: If AIndex is not a valid character index in the string AString, an EArgumentOutOfRangeExcep-
tion (225) exception is raised. If the character at that position is not complete, an EArgumentExcep-
tion (225) exception is raised.
241
CHAPTER 2. REFERENCE FOR UNIT ’CHARACTER’
See also: IsControl (235), IsDigit (236), IsSurrogate (236), IsHighSurrogate (237), IsLowSurrogate (237), Is-
SurrogatePair (237), IsLetter (238), IsLetterOrDigit (238), IsLower (239), IsNumber (239), IsPunc-
tuation (240), IsSeparator (240), IsSymbol (240), IsUpper (241)
2.5.23 TCharacter.ToLower
Synopsis: Convert a character or string to lowercase
Declaration: class function ToLower(AChar: UnicodeChar) : UnicodeChar; Overload
; Static
class function ToLower(const AString: UnicodeString) : UnicodeString
; Overload; Static
class function ToLower(const AString: UnicodeString;
const AOptions: TCharacterOptions) : UnicodeString
; Overload; Static
Visibility: public
Description: ToLower converts the unicode character AChar or string AString to lowercase. Options de-
termines the behaviour of the conversion: if AOptions contains coIgnoreInvalidSequence
then no exception will be raised when the string or character contains an invalid unicode sequence.
The default behaviour is to raise an EArgumentException (225) exception when this happens.
Errors: If an invalid character is encountered, an EArgumentException (225) exception is raised, unless
coIgnoreInvalidSequence is specified in the options.
See also: TCharacter.ToUpper (242), TCharacter.IsLower (239), TCharacter.IsUpper (241)
2.5.24 TCharacter.ToUpper
Synopsis: Convert a character or string to uppercase
Declaration: class function ToUpper(AChar: UnicodeChar) : UnicodeChar; Overload
; Static
class function ToUpper(const AString: UnicodeString) : UnicodeString
; Overload; Static
class function ToUpper(const AString: UnicodeString;
const AOptions: TCharacterOptions) : UnicodeString
; Overload; Static
Visibility: public
Description: ToUpper converts the unicode character AChar or string AString to uppercase. Options de-
termines the behaviour of the conversion: if AOptions contains coIgnoreInvalidSequence
then no exception will be raised when the string or character contains an invalid unicode sequence.
The default behaviour is to raise an EArgumentException (225) exception when this happens.
Errors: If an invalid character is encountered, an EArgumentException (225) exception is raised, unless
coIgnoreInvalidSequence is specified in the options.
See also: TCharacter.ToUpper (242), TCharacter.IsLower (239), TCharacter.IsUpper (241)
242
Chapter 3
Reference for unit ’charset’
3.1 Used units
Table 3.1: Used units by unit ’charset’
Name Page
System 1280
3.2 Overview
The charset unit can be used to load single-byte character set (code page) descriptions. It is used
in the fpwidestring (243) unit to add support for converting single-byte codepage strings to unicode
strings (and vice versa).
Data of a code page may be included using one of the ready-made units, or can be loaded (in a binary
form) at runtime with the loadbinaryunicodemapping (246) function. The binary files have the .bcm
extension and are produced by the creumap utility distributed with Free Pascal.
Pre-made units are available for the following codepages: cp895 (243), cp932 (243), cp936 (243),
cp949 (243) and cp950 (243).
3.3 Constants, types and variables
3.3.1 Constants
BINARY_MAPPING_FILE_EXT = ’.bcm’
BINARY_MAPPING_FILE_EXT contains the default extension of a file containing a binary-coded
map.
3.3.2 Types
preversecharmapping = ^treversecharmapping
Pointer to treversecharmapping
243
CHAPTER 3. REFERENCE FOR UNIT ’CHARSET’
punicodecharmapping = ^tunicodecharmapping
Pointer to tunicodecharmapping
punicodemap = ^tunicodemap
Pointer to tunicodemap
treversecharmapping = packed record
unicode : tunicodechar;
char1
: Byte;
char2 : Byte;
end
treversecharmapping describes how a unicode character can be created in terms of single-byte
characters.
TSerializedMapHeader = packed record
cpName : string;
cp : UInt16
;
mapLength : UInt32;
lastChar : Int32;
reverseMapLength : UInt32
;
end
TSerializedMapHeader is a record describing the binary map data file. The contents of this
record can be found at offset zero of a (.bcm) file containing a single-byte unicode map.
tunicodechar = Word
tunicodechar is a type used to represent unicode characters in this file, it should not be used for
other unicode routines.
tunicodecharmapping = packed record
unicode : tunicodechar;
flag
: tunicodecharmappingflag;
reserved : Byte;
end
tunicodecharmapping describes a unicode character. An array of these mappings is built for
each character in the single-byte character set,
tunicodecharmappingflag = (umf_noinfo,umf_leadbyte,umf_undefined,
umf_unused)
244
CHAPTER 3. REFERENCE FOR UNIT ’CHARSET’
Table 3.2: Enumeration values for type tunicodecharmappingflag
Value Explanation
umf_leadbyte Unicode character uses leading byte
umf_noinfo No extra information about unicode character
umf_undefined Currently unused
umf_unused Unused position in code page
tunicodecharmappingflag contains various Flags describing information about a unicode
character.
tunicodemap = record
cpname : string;
cp : Word;
map : punicodecharmapping
;
lastchar : LongInt;
reversemap : preversecharmapping;
reversemaplength
: LongInt;
next : punicodemap;
internalmap : Boolean;
end
tunicodemap describes a complete mapping between a single-byte code page and a unicode char-
acter set. It contains both a forward and backward mapping.
tunicodestring = ^tunicodechar
tunicodestring is a type used to represent unicode strings in this file, it should not be used for
other unicode routines.
3.4 Procedures and functions
3.4.1 getascii
Synopsis: Convert unicode character or string to single-byte character or string.
Declaration: function getascii(c: tunicodechar; p: punicodemap) : string
function getascii(c: tunicodechar; p: punicodemap; ABuffer: PAnsiChar;
ABufferLen: LongInt) : LongInt
Visibility: default
Description: getascii converts a unicode character c to one or more single-byte characters according to the
map in p. The result can be a string containing up to 2 characters, or the number of characters copied
to the buffer ABuffer with length ABufferLen.
Errors: If the character cannot be translated, ASCII character 63 is returned (or copied to the buffer). In the
case of the buffer variant of the function, -1 is then returned. If the buffer is not large enough, -1 is
returned.
See also: getunicode (246)
245
CHAPTER 3. REFERENCE FOR UNIT ’CHARSET’
3.4.2 getmap
Synopsis: Find a codepage map
Declaration: function getmap(const s: string) : punicodemap
function getmap(cp: Word) : punicodemap
Visibility: default
Description: getmap looks in the registered codepage mappings and returns the mapping for the requested code-
page. The codepage can be specified using a name s or a numerical identifier cp. The search is case
sensitive.
Errors: if the requested map is not found, Nil is returned.
See also: registermapping (248), registerbinarymapping (247), mappingavailable (247)
3.4.3 getunicode
Synopsis: Map single-byte character to unicode character.
Declaration: function getunicode(c: Char; p: punicodemap) : tunicodechar
function getunicode(AAnsiStr: PAnsiChar; AAnsiLen: LongInt;
AMap: punicodemap; ADest: tunicodestring) : LongInt
Visibility: default
Description: The first form of getunicode will map a single character c to its unicode equivalent for mapping
p. If no equivalent can be found, 0 is returned.
The second form of getunicode will transform a string (specified using a pointer AAnsiStr to a
buffer with length AAnsiLen) to a unicode string using single byte codepage map AMap. It returns
the number of unicode characters. If ADest is Nil then just the number of characters is returned.
If ADest is not nil, it must point to a buffer large enough to contain the unicode string, and the
converted string will be copied to it.
Errors: No checking on the validity of the buffers is done.
See also: getascii (245)
3.4.4 loadbinaryunicodemapping
Synopsis: Load binary single-byte codepage to unicode map from file or memory
Declaration: function loadbinaryunicodemapping(const directory: string;
const cpname: string) : punicodemap
; Overload
function loadbinaryunicodemapping(const filename: string) : punicodemap
; Overload
function loadbinaryunicodemapping(const AData: Pointer;
const ADataLength: Integer)
: punicodemap; Overload
Visibility: default
Description: loadbinaryunicodemapping loads a binary description of a single-byte unicode mapping.
The mapping can reside in a file, in which case the file to load can be specified using a filename
filename or using a directory directory and codepage name cpname. In the latter case, a
246
CHAPTER 3. REFERENCE FOR UNIT ’CHARSET’
suffix consisting of _le or _be depending on the endianness of the current platform will be appended,
and the filename extension is .bcm. Note that the file names may be case sensitive.
The data can also be loaded from a memory block AData with size ADataLength.
It will produce an in-memory map of the file. It returns a pointer to the map, or Nil if something
went wrong. The resulting mapping can be registered using registermapping (248).
Errors: On error, Nil is returned.
See also: loadunicodemapping (247), registermapping (248)
3.4.5 loadunicodemapping
Synopsis: Load textual single-byte codepage to unicode map from file
Declaration: function loadunicodemapping(const cpname: string; const f: string;
cp: Word) : punicodemap
Visibility: default
Description: loadunicodemapping loads a text description of a single-byte unicode mapping. It will analyse
the textual description in file f, and produce an in-memory map of the file. It returns a pointer to the
map, or Nil if something went wrong. The unicode map name must be specified in cpName, and
the numerical identifier in cp
The resulting mapping can be registered using registermapping (248).
Errors: On error, Nil is returned.
See also: loadbinaryunicodemapping (246), registermapping (248)
3.4.6 mappingavailable
Synopsis: Check if a mapping is available for a specified code page.
Declaration: function mappingavailable(const s: string) : Boolean
function mappingavailable(cp: Word) : Boolean
Visibility: default
Description: mappingavailable returns True if a mapping for a specified code page (using name s or
numerical identifier cp) is available, or False if it is not.
See also: registermapping (248), registerbinarymapping (247), getmap (246)
3.4.7 registerbinarymapping
Synopsis: Load and register binary single-byte codepage to unicode map from file
Declaration: function registerbinarymapping(const directory: string;
const cpname: string) : Boolean
Visibility: default
Description: registerbinarymapping calls loadbinaryunicodemapping (246) using directory and cpname
and registers the resulting mapping, if any was succesfully loaded, using registermapping (248). It
returns True if the operation was succesful.
Errors: On error, False is returned.
See also: loadbinaryunicodemapping (246), registermapping (248)
247
CHAPTER 3. REFERENCE FOR UNIT ’CHARSET’
3.4.8 registermapping
Synopsis: Register mapping
Declaration: procedure registermapping(p: punicodemap)
Visibility: default
Description: RegisterMapping registers mapping p in the registry of single-byte codepages. No attempt is
made to avoid double registrations. In case of doubles, the last registered mapping will be used first.
See also: loadunicodemapping (247), loadbinaryunicodemapping (246), registerbinarymapping (247)
248
Chapter 4
Reference for unit ’Classes’
4.1 Used units
Table 4.1: Used units by unit ’Classes’
Name Page
rtlconsts ??
System 1280
sysutils 1538
Types 1809
typinfo 1846
4.2 Overview
This documentation describes the FPC classes unit. The Classes unit contains basic classes for the
Free Component Library (FCL):
• a TList (388) class for maintaining lists of pointers,
• TStringList (442) for lists of strings,
• TCollection (338) to manage collections of objects
• TStream (427) classes to support streaming.
Furthermore it introduces methods for object persistence, and classes that understand an owner-
owned relationship, with automatic memory management.
4.3 Constants, types and variables
4.3.1 Constants
BITSHIFT = 5
Used to calculate the size of a bits array
249
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
dupAccept = Types.dupAccept
Duplicate values can be added to the list.
dupError = Types.dupError
If an attempt is made to add a duplicate value to the list, an EStringListError (286) exception is
raised.
dupIgnore = Types.dupIgnore
Duplicate values will not be added to the list, but no error will be triggered.
FilerSignature : Array[1..4] of Char = ’TPF0’
Constant that is found at the start of a binary stream containing a streamed component.
fmCreate = $FF00
TFileStream.Create (368) creates a new file if needed.
fmOpenRead = 0
TFileStream.Create (368) opens a file with read-only access.
fmOpenReadWrite = 2
TFileStream.Create (368) opens a file with read-write access.
fmOpenWrite = 1
TFileStream.Create (368) opens a file with write-only access.
MASK = 31
Bitmask with all bits on.
MaxBitFlags = $7FFFFFE0
Maximum number of bits in TBits collection.
MaxBitRec = MaxBitFlags div ((cardinal) * 8)
Maximum number of bit records in TBits.
MaxListSize = Maxint div 16
This constant sets the maximum number of elements in a TList (388).
scAlt = $8000
250
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
Indicates ALT key in a keyboard shortcut.
scCtrl = $4000
indicates CTRL key in a keyboard shortcut.
scNone = 0
Indicates no special key is presed in a keyboard shortcut.
scShift = $2000
Indicates Shift key in a keyboard shortcut.
SGUIDObserved = ’{663C603C-3F3C-4CC5-823C-AC8079F979E5}’
Observed interface GUID as a string
SGUIDObserver = ’{BC7376EA-199C-4C2A-8684-F4805F0691CA}’
Observer interface GUID as a string
soFromBeginning = 0
Seek (429) starts relative to the stream origin.
soFromCurrent = 1
Seek (429) starts relative to the current position in the stream.
soFromEnd = 2
Seek (429) starts relative to the stream end.
toEOF = (0)
Value returned by TParser.Token (407) when the end of the input stream was reached.
toFloat = (4)
Value returned by TParser.Token (407) when a floating point value was found in the input stream.
toInteger = (3)
Value returned by TParser.Token (407) when an integer was found in the input stream.
toString = (2)
Value returned by TParser.Token (407) when a string was found in the input stream.
toSymbol = (1)
Value returned by TParser.Token (407) when a symbol was found in the input stream.
toWString = (5)
Value returned by TParser.Token (407) when a widestring was found in the input stream.
251
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.3.2 Types
HMODULE = PtrInt
FPC doesn’t support modules yet, so this is a dummy type.
HRSRC = TFPResourceHandle deprecated
This type is provided for Delphi compatibilty, it is used for resource streams.
PPointerList = ^TPointerList
Pointer to an array of pointers.
PStringItem = ^TStringItem
Pointer to a TStringItem (263) record.
PStringItemList = ^TStringItemList
Pointer to a TStringItemList (263).
TActiveXRegType = (axrComponentOnly,axrIncludeDescendants)
Table 4.2: Enumeration values for type TActiveXRegType
Value Explanation
axrComponentOnly
axrIncludeDescendants
This type is provided for compatibility only, and is currently not used in Free Pascal.
TAlignment = (taLeftJustify,taRightJustify,taCenter)
Table 4.3: Enumeration values for type TAlignment
Value Explanation
taCenter Text is displayed centered.
taLeftJustify Text is displayed aligned to the left
taRightJustify Text is displayed aligned to the right.
The TAlignment type is used to specify the alignment of the text in controls that display a text.
TAncestorNotFoundEvent = procedure(Reader: TReader;
const ComponentName: string;
ComponentClass: TPersistentClass;
var Component: TComponent) of object
252
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
This event occurs when an ancestor component cannot be found.
TBasicActionClass = Class of TBasicAction
TBasicAction (312) class reference.
TBasicActionLinkClass = Class of TBasicActionLink
TBasicActionLink (316) class reference.
TBiDiMode = (bdLeftToRight,bdRightToLeft,bdRightToLeftNoAlign,
bdRightToLeftReadingOnly)
Table 4.4: Enumeration values for type TBiDiMode
Value Explanation
bdLeftToRight Texts read from left to right.
bdRightToLeft Texts read from right to left.
bdRightToLeftNoAlign Texts read from right to left, but not right-aligned
bdRightToLeftReadingOnly Texts read from right to left
TBiDiMode describes bi-directional support for displaying texts.
TBitArray = Array[0..MaxBitRec-1] of Cardinal
Array to store bits.
TCollectionItemClass = Class of TCollectionItem
TCollectionItemClass is used by the TCollection.ItemClass (344) property of TCollection
(338) to identify the descendant class of TCollectionItem (346) which should be created and man-
aged.
TCollectionNotification = (cnAdded,cnExtracting,cnDeleting)
Table 4.5: Enumeration values for type TCollectionNotification
Value Explanation
cnAdded An item is added to the collection.
cnDeleting An item is deleted from the collection.
cnExtracting An item is extracted from the collection.
TCollectionNotification is used in the TCollection (338) class to send notifications about
changes to the collection.
TCollectionSortCompare = function(Item1: TCollectionItem;
Item2: TCollectionItem) : Integer
253
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
TCollectionSortCompare is the prototype for a callback used in the TCollection.Sort (343)
method. The procedure should compare Item1 and Item2 and return an integer:
Result < 0 if Item1 comes before Item2
Result = 0 if Item1 is at the same level as Item2
Result > 0 if Item1 comes after Item2
TComponentClass = Class of TComponent
The TComponentClass type is used when constructing TComponent (348) descendant instances
and when registering components.
TComponentName = String
Names of components are of type TComponentName. By specifying a different type, the Object
inspector can handle this property differently than a standard string property.
TComponentState= Set of (csLoading,csReading,csWriting,csDestroying
,
csDesigning,csAncestor,csUpdating,csFixups
,
csFreeNotification,csInline,csDesignInstance
)
Table 4.6: Enumeration values for type
Value Explanation
csAncestor The component is being streamed as part of a frame (?)
csDesigning The component is being designed in an IDE.
csDesignInstance ??
csDestroying The component is being destroyed.
csFixups The component’s references to other components are being fixed.
csFreeNotification Indicates whether the component has freenotifications
csInline Component is part of a frame (?).
csLoading The component is being loaded from the stream.
csReading Properties are being read from the stream.
csUpdating The component is being updated.
csWriting Properties are being written to the stream.
The following values are possible:
csLoading The component (and all child components) are being loaded from a stream. This means
that a TReader (412) instance is reading properties from this and child components from a
stream and is applying the values found in the stream to the properties.
csReading The properties of this component are being read from a stream. This means that a
TReader (412) instance is reading properties from this component from a stream and is ap-
plying the values.
254
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
csWriting The properties of this component are being written to a stream. This means that a TWriter
(484) instance is writing properties from this component to a stream.
csDestroying The component is being destroyed.
csDesigning The component is being designed in an IDE.
csAncestor The component has a design ancestor. This is used to record differences between a com-
ponent and it’s design ancestor. For example a form TForm2 inherited from a form TForm1.
TForm1 and all its components are copied to TForm2. TForm2 and all its inherited compo-
nents have csAncestor set. Only differences between TForm1 and TForm2 are stored in
the stream of TForm2. The child components of a frame put onto a form have csAncestor
too.
csInline The component is a nested top level component. For example a frame on a form. The
children of the frame do not have csInline, unless they are other frames.
csDesignInstance The component is designed (csDesigning) and is a root component, meaning
it has no owner (Owner=nil).
csFixups The component’s references to other components are being fixed. While reading a compo-
nent from stream, it can happen that the stream contains a component reference property with
a name of a component that was not yet created and read from the stream. Such properties
are saved, and the missing references are resolved when the complete stream was read. This
resolving step is called fixing up references, and the csFixups flags is set during this step.
csFreeNotification This flag indicates that the component has free notifications registered with
TComponent.FreeNotification (352)
TComponentStyle= Set of (csInheritable,csCheckPropAvail,csSubComponent
,
csTransient)
Table 4.7: Enumeration values for type
Value Explanation
csCheckPropAvail ??
csInheritable The component can be on inherited forms.
csSubComponent Subcomponent - streamed as part of the owning component
csTransient Transient component
Describes the style of the component.
TCreateComponentEvent = procedure(Reader: TReader;
ComponentClass: TComponentClass;
var Component: TComponent) of object
Event handler type, occurs when a component instance must be created when a component is read
from a stream.
TDataModuleClass = Class of TDataModule
TDataModuleClass defines the class pointer for TDataModule (362).
255
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
TDuplicates = Types.TDuplicates
Type to describe what to do with duplicate values in a TStringlist (442).
TExceptionClass = Class of Exception
TExceptionClass is the class pointer for the Exception (1716) class, defined in the SysUtils
(1538) unit.
TFilerFlag = (ffInherited,ffChildPos,ffInline)
Table 4.8: Enumeration values for type TFilerFlag
Value Explanation
ffChildPos The position of the child on it’s parent is included.
ffInherited Stored object is an inherited object.
ffInline Used for frames.
The TFiler class uses this enumeration type to decide whether the streamed object was streamed
as part of an inherited form or not.
TFilerFlags = Set of TFilerFlag
Set of TFilerFlag (256)
TFindAncestorEvent = procedure(Writer: TWriter; Component: TComponent
;
const Name: string;
var Ancestor: TComponent;
var RootAncestor: TComponent) of object
Event that occurs w
TFindComponentClassEvent = procedure(Reader: TReader;
const ClassName: string;
var ComponentClass: TComponentClass)
of object
Event handler type, occurs when a component class pointer must be found when reading a component
from a stream.
TFindGlobalComponent = function(const Name: string) : TComponent
TFindGlobalComponent is a callback used to find a component in a global scope. It is used
when the streaming system needs to find a component which is not part of the component which is
currently being streamed. It should return the component with name Name, or Nil if none is found.
The variable FindGlobalComponent (271) is a callback of type TFindGlobalComponent. It can
be set by the IDE when an unknown reference is found, to offer the designer to redirect the link to a
new component.
256
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
TFindMethodEvent = procedure(Reader: TReader; const MethodName: string
;
var Address: CodePointer;
var Error: Boolean) of object
If a TReader (412) instance needs to locate a method and it doesn’t find it in the streamed form, then
the OnFindMethod (423) event handler will be called, if one is installed. This event can be assigned
in order to use different locating methods. If a method is found, then its address should be returned
in Address. The Error should be set to True if the reader should raise an exception after the
event was handled. If it is set to False no exception will be raised, even if no method was found.
On entry, Error will be set to True.
TFPObservedOperation = (ooChange,ooFree,ooAddItem,ooDeleteItem,ooCustom
)
Table 4.9: Enumeration values for type TFPObservedOperation
Value Explanation
ooAddItem An item is added to the observed object (generally a list).
ooChange The observed object has changed.
ooCustom Custom event.
ooDeleteItem An item is deleted from the observed object (generally a list).
ooFree The observed object is being freed.
TFPObservedOperation enumerates the possible operations that can be reported to an observer.
Which of these operations is reported depends on the implementation of the observed object.
TGetChildProc = procedure(Child: TComponent) of object
Callback used when obtaining child components.
TGetStrProc = procedure(const S: string) of object
This event is used as a callback to retrieve string values. It is used, among other things, to pass along
string properties in property editors.
THandle = System.THandle
This type is used as the handle for THandleStream (378) stream descendants
THelpContext = -MaxLongint..MaxLongint
Range type to specify help contexts.
THelpEvent = function(Command: Word; Data: LongInt;
var CallHelp: Boolean) : Boolean of object
This event is used for display of online help.
THelpType = (htKeyword,htContext)
257
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
Table 4.10: Enumeration values for type THelpType
Value Explanation
htContext Help type: Context ID help.
htKeyword Help type: Keyword help
Enumeration type specifying the kind of help requested.
TIdentMapEntry = record
Value : Integer;
Name : string;
end
TIdentMapEntry is used internally by the IdentToInt (273) and IntToIdent (274) calls to store the
mapping between the identifiers and the integers they represent.
TIdentToInt = function(const Ident: string; var Int: LongInt) :
Boolean
TIdentToInt is a callback used to look up identifiers (Ident) and return an integer value cor-
responding to this identifier (Int). The callback should return True if a value corresponding to
integer Ident was found, False if not.
A callback of type TIdentToInt should be specified when an integer is registered using the Reg-
isterIntegerConsts (279) call.
TInitComponentHandler = function(Instance: TComponent;
RootAncestor: TClass) : Boolean
TInitComponentHandler is a callback type. It is used in the InitInheritedComponent (274)
call to initialize a component. Callbacks of this type are registered with the RegisterInitComponen-
tHandler (279) call.
TIntToIdent = function(Int: LongInt; var Ident: string) : Boolean
TIdentToInt is a callback used to look up integers (Ident) and return an identifier (Ident)
that can be used to represent this integer value in an IDE. The callback should return True if a value
corresponding to integer Ident was found, False if not.
A callback of type TIntToIdent should be specified when an integer is registered using the Reg-
isterIntegerConsts (279) call.
TLeftRight = taLeftJustify..taRightJustify
TLeftRight is a subrange type based on the TAlignment (252) enumerated type. It contains only
the left and right alignment constants.
TListAssignOp = (laCopy,laAnd,laOr,laXor,laSrcUnique,laDestUnique
)
258
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
Table 4.11: Enumeration values for type TListAssignOp
Value Explanation
laAnd Remove all elements not first second list
laCopy Clear list and copy all strings from second list.
laDestUnique Keep all elements that exists only in list2
laOr Add all elements from second (and optional third) list, eliminate duplicates
laSrcUnique Just keep all elements that exist only in source list
laXor Remove elements in second lists, Add all elements from second list not in first list
This type determines what operation TList.Assign (394) or TFPList.assign (374) performs.
TListCallback = Types.TListCallback
TListCallback is the method callback prototype for the function that is passed to the TF-
PList.ForEachCall (375) call. The data argument will be filled with all the pointers in the list
(one per call) and the arg argument is the Arg argument passed to the ForEachCall call.
TListNotification = (lnAdded,lnExtracted,lnDeleted)
Table 4.12: Enumeration values for type TListNotification
Value Explanation
lnAdded List change notification: Element added to the list.
lnDeleted List change notification: Element deleted from the list.
lnExtracted List change notification: Element extracted from the list.
Kind of list notification event.
TListSortCompare = function(Item1: Pointer; Item2: Pointer) :
Integer
Callback type for the list sort algorithm.
TListStaticCallback = Types.TListStaticCallback
TListCallback is the procedurald callback prototype for the function that is passed to the TF-
PList.ForEachCall (375) call. The data argument will be filled with all the pointers in the list (one
per call) and the arg argument is the Arg argument passed to the ForEachCall call.
TNotifyCallBack = procedure(Sender: TObject; AData: Pointer)
TNotifyCallBack is used to notify about thread termination when using static callbacks. When
called, the Sender will contain the thread which is terminating, and AData is the AData parameter
passed to TThread.ExecuteInThread (472).
TNotifyEvent = procedure(Sender: TObject) of object
259
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
Most event handlers are implemented as a property of type TNotifyEvent. When this is set to
a certain method of a class, when the event occurs, the method will be called, and the class that
generated the event will pass itself along as the Sender argument.
TObjectTextEncoding = (oteDFM,oteLFM)
Table 4.13: Enumeration values for type TObjectTextEncoding
Value Explanation
oteDFM Characters are in DFM (Delphi) format: widechar encoded.
oteLFM Characters are in LFM format: UTF-8 encoded.
TObjectTextEncoding is an enumerated type which denotes the encoding of non ascii charac-
ters in an object stream file. It is needed for correct encoding when reading string values in the text
stream.
TOperation = (opInsert,opRemove)
Table 4.14: Enumeration values for type TOperation
Value Explanation
opInsert A new component is being inserted in the child component list.
opRemove A component is being removed from the child component list.
Operation of which a component is notified.
TPersistentClass = Class of TPersistent
TPersistentClass is the class reference type for the TPersistent (408) class.
TPoint = Types.TPoint
This record describes a coordinate. It is used to handle the Top (348) and Left (348) properties of
TComponent (348).
X represents the X-Coordinate of the point described by the record. Y represents the Y-Coordinate of
the point described by the record.
TPointerList = Array[0..MaxListSize-1] of Pointer
Type for an Array of pointers.
TPropertyNotFoundEvent = procedure(Reader: TReader;
Instance: TPersistent;
var PropName: string;
IsPath: Boolean;
var
Handled: Boolean;
var Skip: Boolean
) of object
260
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
TPropertyNotFoundEvent is the prototype for the TReader.OnPropertyNotFound (422) event.
Reader is the sender of the event, Instance is the instance that is being streamed. PropInfo
is a pointer to the RTTI information for the property being read. Handled should be set to True
if the handler redirected the unknown property succesfully, and Skip should be set to True if the
value should be skipped. IsPath determines whether the property refers to a sub-property.
TReadComponentsProc = procedure(Component: TComponent) of object
Callback type when reading a component from a stream
TReaderError = procedure(Reader: TReader; const Message: string;
var Handled: Boolean) of object
Event handler type, called when an error occurs during the streaming.
TReaderProc = procedure(Reader: TReader) of object
The TReaderProc reader procedure is a callback procedure which will be used by a TPersistent
(408) descendant to read user properties from a stream during the streaming process. The Reader
argument is the writer object which can be used read properties from the stream.
TReadWriteStringPropertyEvent = procedure(Sender: TObject;
const Instance: TPersistent;
PropInfo: PPropInfo;
var Content: string) of
object
TReadWriteStringPropertyEvent is the prototype for the TReader.OnReadStringProperty
(424) event handler. Reader is the sender of the event, Instance is the instance that is being
streamed. PropInfo is a pointer to the RTTI information for the property being read. Content is
the string as it was read from the stream.
TRect = Types.TRect
TRect describes a rectangle in space with its upper-left (in (Top,Left>)) and lower-right (in
(Bottom ,Right)) corners.
TReferenceNameEvent = procedure(Reader: TReader; var Name: string
)
of object
Occurs when a named object needs to be looked up.
TSeekOrigin = (soBeginning,soCurrent,soEnd)
Table 4.15: Enumeration values for type TSeekOrigin
Value Explanation
soBeginning Offset is interpreted relative to the start of the stream.
soCurrent Offset is interpreted relative to the current position in the stream.
soEnd Offset is interpreted relative to the end of the stream.
Specifies the origin of the TStream.Seek (429) method.
261
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
TSetMethodPropertyEvent = procedure(Reader: TReader;
Instance: TPersistent;
PropInfo: PPropInfo;
const TheMethodName: string;
var Handled: Boolean) of object
TSetMethodPropertyEvent is the prototype for the TReader.OnSetMethodProperty (423) event.
Reader is the sender of the event, Instance is the instance that is being streamed. PropInfo
is a pointer to the RTTI information for the property being read, and TheMethodName is the name
of the method that the property should be set to. Handled should be set to True if the handler set
the property succesfully.
TSetNameEvent = procedure(Reader: TReader; Component: TComponent;
var Name: string) of object
Occurs when the reader needs to set a component’s name.
TShiftState = Set of TShiftStateEnum
This type is used when describing a shortcut key or when describing what special keys are pressed
on a keyboard when a key event is generated.
The set contains the special keys that can be used in combination with a ’normal’ key.
TShiftStateEnum = (ssShift,ssAlt,ssCtrl,ssLeft,ssRight,ssMiddle,
ssDouble,ssMeta,ssSuper,ssHyper,ssAltGr,ssCaps
,ssNum,
ssScroll,ssTriple,ssQuad,ssExtra1,ssExtra2
)
Table 4.16: Enumeration values for type TShiftStateEnum
Value Explanation
ssAlt Alt key pressed
ssAltGr Alt-GR key pressed.
ssCaps Caps lock key pressed
ssCtrl Ctrl key pressed
ssDouble Double mouse click.
ssExtra1 Extra key 1
ssExtra2 Extra key 2
ssHyper Hyper key pressed.
ssLeft Left mouse button pressed.
ssMeta Meta key pressed.
ssMiddle Middle mouse button pressed.
ssNum Num lock key pressed
ssQuad Quadruple mouse click
ssRight Right mouse button pressed.
ssScroll Scroll lock key pressed
ssShift Shift key pressed
ssSuper Super key pressed.
ssTriple Triple mouse click
Keyboard/Mouse shift state enumerator
262
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
TShortCut = (Word)..(Word)
Enumeration type to identify shortcut key combinations.
TSmallPoint = record
x : SmallInt;
y : SmallInt;
end
Same as TPoint (260), only the X and Y ranges are limited to 2-byte integers instead of 4-byte
integers.
TStreamOwnership = (soReference,soOwned)
Table 4.17: Enumeration values for type TStreamOwnership
Value Explanation
soOwned Stream is owned: it will be freed when the adapter is freed.
soReference Stream is referenced only, it is not freed by the adapter
The ownership of a streamadapter determines what happens with the stream on which a TStrea-
mAdapter (437) acts, when the adapter is freed.
TStreamProc = procedure(Stream: TStream) of object
Procedure type used in streaming.
TStringItem = record
FString : string;
FObject : TObject;
end
The TStringItem is used to store the string and object items in a TStringList (442) string list
instance. It should never be used directly.
TStringItemList = Array[0..MaxListSize] of TStringItem
This declaration is provided for Delphi compatibility, it is not used in Free Pascal.
TStringListSortCompare = function(List: TStringList; Index1: Integer
;
Index2: Integer) : Integer
Callback type used in stringlist compares.
TStringsSortStyle = (sslNone,sslUser,sslAuto)
263
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
Table 4.18: Enumeration values for type TStringsSortStyle
Value Explanation
sslAuto The TStrings instance keeps the strings sorted.
sslNone The strings are not sorted
sslUser The strings are kept sorted by the user.
TStringsSortStyle is the type used in the TStringList.SortStyle (447) property, and describes
how the strings are sorted when the TStringList.Sorted (445) property is True. It has the following
values:
sslNone The strings are not sorted
sslUser The strings are kept sorted by the user.
sslAuto The TStrings instance keeps the strings sorted.
TStringsSortStyles = Set of TStringsSortStyle
TStringsSortStyles is the set type for enumeration TStringsSortStyle (264).
TSynchronizeProcVar = procedure
Synchronize callback type
TThreadExecuteCallBack = procedure(AData: Pointer)
TThreadExecuteCallBack is the signature of the static procedure to be used when executing
something in a thread using TThread.ExecuteInThread (472) when no status reporting is required.
TThreadExecuteHandler = TThreadMethod
TThreadExecuteHandler is the signature of the method to be used when executing something
in a thread using TThread.ExecuteInThread (472) when no status reporting is required.
TThreadExecuteStatusCallBack = procedure(AData: Pointer;
ReportStatus: TThreadReportStatus
)
TThreadExecuteStatusCallBack is the signature of a procedure to be used when executing
something in a thread using TThread.ExecuteInThread (472) when status reporting is required.
On entry in the method, AData is the AData parameter passed to TThread.ExecuteInThread (472).
ReportStatus is passed to the method, and the threaded procedure can call ReportStatus at
various stages to report about the status of the method: The status will be reported to the main thread
using TThread.synchronize (469), so calls to ReportStatus will be blocked as long as the status
was not reported.
TThreadExecuteStatusHandler = procedure
(ReportStatus: TThreadReportStatus)
of object
264
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
TThreadExecuteStatusHandler is the signature of the method to be used when executing
something in a thread using TThread.ExecuteInThread (472) when status reporting is required.
On entry in the method, ReportStatus is passed to the method, and the method can call ReportStatus
at various stages to report about the status of the method: The status will be reported to the main
thread using TThread.synchronize (469), and calls ReportStatus will be blocked as long as the
status was not reported.
TThreadMethod = procedure of object
Procedure variable used when synchronizing threads.
TThreadPriority = (tpIdle,tpLowest,tpLower,tpNormal,tpHigher,tpHighest
,
tpTimeCritical)
Table 4.19: Enumeration values for type TThreadPriority
Value Explanation
tpHigher Thread runs at high priority
tpHighest Thread runs at highest possible priority.
tpIdle Thread only runs when other processes are idle.
tpLower Thread runs at a lower priority.
tpLowest Thread runs at the lowest priority.
tpNormal Thread runs at normal process priority.
tpTimeCritical Thread runs at realtime priority.
Enumeration specifying the priority at which a thread runs.
TThreadReportStatus = procedure(const status: string) of object
TThreadReportStatus is the callback prototype for the TThread.ExecuteInThread (472) method.
This callback is used to report thread status to the main thread: the Status string can be used to
report the status of thread execution.
TThreadStatusNotifyCallBack = procedure(Sender: TThread;
AData: Pointer;
const status: string)
TThreadStatusNotifyCallBack is the signature of the callback to be provided when exe-
cuting a static procedure in a thread using TThread.ExecuteInThread (472) when status reporting is
required.
This callback will be called in the main thread. When called, it has the thread whose status is reported
in Sender, AData is the AData parameter passed to TThread.ExecuteInThread (472). Finally, the
status message in ReportStatus is passed to the callback.
Note that the thread reporting its status is blocked while the callback is being handled: The status is
be reported to the main thread using TThread.synchronize (469).
TThreadStatusNotifyEvent = procedure(Sender: TThread;
const status: string) of object
265
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
TThreadStatusNotifyEvent is the signature of the method to be provided when executing
something in a thread using TThread.ExecuteInThread (472) when status reporting is required.
This event handler will be called in the main thread. When called, it has the thread whose status is
reported in Sender, and the status message in ReportStatus is passed to the method.
Note that the thread reporting its status is blocked while the callback is being handled: The status is
be reported to the main thread using TThread.synchronize (469).
TValueType = (vaNull,vaList,vaInt8,vaInt16,vaInt32,vaExtended,vaString
,
vaIdent,vaFalse,vaTrue,vaBinary,vaSet,vaLString,vaNil
,
vaCollection,vaSingle,vaCurrency,vaDate,vaWString
,vaInt64,
vaUTF8String,vaUString,vaQWord)
Table 4.20: Enumeration values for type TValueType
Value Explanation
vaBinary Binary data follows.
vaCollection Collection follows
vaCurrency Currency value follows
vaDate Date value follows
vaExtended Extended value.
vaFalse Boolean False value.
vaIdent Identifier.
vaInt16 Integer value, 16 bits long.
vaInt32 Integer value, 32 bits long.
vaInt64 Integer value, 64 bits long.
vaInt8 Integer value, 8 bits long.
vaList Identifies the start of a list of values
vaLString Ansistring data follows.
vaNil Nil pointer.
vaNull Empty value. Ends a list.
vaQWord QWord (64-bit word) value
vaSet Set data follows.
vaSingle Single type follows.
vaString String value.
vaTrue Boolean True value.
vaUString UnicodeString value
vaUTF8String UTF8 encoded unicode string.
vaWString Widestring value follows.
Enumerated type used to identify the kind of streamed property
TWriteMethodPropertyEvent = procedure(Writer: TWriter;
Instance: TPersistent;
PropInfo: PPropInfo;
const MethodValue: TMethod;
const DefMethodValue: TMethod;
var Handled: Boolean) of object
266
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
TWriteMethodPropertyEvent is the prototype for the TWriter.OnWriteMethodProperty (491)
event. Writer is the sender of the event, Instance is the instance that is being streamed.
PropInfo is a pointer to the RTTI information for the property being written, and MethodValue
is the value of the method that the property was set to. DefMethodCodeValue is set to the default
value of the property (Nil or the parent value). Handled should be set to True if the handler set
the property succesfully.
TWriterProc = procedure(Writer: TWriter) of object
The TWriterProc writer procedure is a callback procedure which will be used by a TPersistent
(408) descendant to write user properties from a stream during the streaming process. The Writer
argument is the writer object which can be used write properties to the stream.
4.3.3 Variables
AddDataModule : procedure(DataModule: TDataModule) of object
AddDataModule can be set by an IDE or a streaming mechanism to receive notification when a
new instance of a TDataModule (362) descendant is created.
ApplicationHandleException : procedure(Sender: TObject) of object
ApplicationHandleException can be set by an application object to handle any exceptions
that may occur when a TDataModule (362) is created.
ApplicationShowException : procedure(E: Exception) of object
Unused.
CreateVCLComObjectProc : procedure(Component: TComponent) = Nil
CreateVCLComObjectProc is called by TComponent if it needs to create a IVCLComObject
interface for itself (when the ComObject property is read). It passes itself as the Component pa-
rameter.
GlobalNameSpace : IReadWriteSync
An interface protecting the global namespace. Used when reading/writing to the global namespace
list during streaming of forms.
MainThreadID : TThreadID
ID of main thread. Unused at this point.
RegisterComponentsProc : procedure(const Page: string;
ComponentClasses: Array of TComponentClass)
RegisterComponentsProc can be set by an IDE to be notified when new components are being
registered. Application programmers should never have to set RegisterComponentsProc
RegisterNoIconProc : procedure(ComponentClasses: Array of TComponentClass
)
267
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
RegisterNoIconProc can be set by an IDE to be notified when new components are being
registered, and which do not need an Icon in the component palette. Application programmers should
never have to set RegisterComponentsProc
RemoveDataModule : procedure(DataModule: TDataModule) of object
RemoveDataModule can be set by an IDE or a streaming mechanism to receive notification when
an instance of a TDataModule (362) descendant is freed.
WakeMainThread : TNotifyEvent = Nil
WakeMainThread is a handler, which, when set, is called by the TThread.Synchronize (469) rou-
tine to signal the main thread that a synchronization routine is waiting in the queue.
This handler is by default empty. An actual implementation depends on the main program logic
(usually an event loop) and must be provided by the event loop logic: the event loop will normally call
CheckSynchronize (269) at regular intervals. The WakeMainThread can make sure this happens
as soon as possible.
While this handle should alert the main program thread that a thread is waiting for synchronization,
the call is executed by the thread, and should therefore NOT synchronize the thread, but should
somehow signal the main thread that a thread is waiting for synchronization. For example, by sending
a message.
4.4 Procedures and functions
4.4.1 ActivateClassGroup
Synopsis: Activates a class group
Declaration: function ActivateClassGroup(AClass: TPersistentClass) : TPersistentClass
Visibility: default
Description: ActivateClassGroup activates the group of classes to which AClass belongs. The function
returns the class that was last used to activate the class group.
The class registration and streaming mechanism allows to organize the classes in groups. This allows
an IDE to form groups of classes, which can be enabled or disabled. It is not needed at Run-Time.
Errors: If AClass does not belong to a class group, an exception is raised.
See also: StartClassGroup (281), GroupDescendantsWith (249), ClassGroupOf (270)
4.4.2 BeginGlobalLoading
Synopsis: Not yet implemented
Declaration: procedure BeginGlobalLoading
Visibility: default
Description: Not yet implemented
268
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.4.3 BinToHex
Synopsis: Convert a binary buffer to a hexadecimal string
Declaration: procedure BinToHex(BinValue: PChar; HexValue: PChar;
BinBufSize: Integer)
Visibility: default
Description: BinToHex converts the byte values in BinValue to a string consisting of 2-charachter hex-
adecimal strings in HexValue. BufSize specifies the length of BinValue, which means that
HexValue must have size 2*BufSize.
For example a buffer containing the byte values 255 and 0 will be converted to FF00.
Errors: No length checking is done, so if an invalid size is specified, an exception may follow.
See also: HexToBin (273)
4.4.4 Bounds
Synopsis: Returns a TRect structure with the bounding rect of the given location and size.
Declaration: function Bounds(ALeft: Integer; ATop: Integer; AWidth: Integer;
AHeight: Integer) : TRect
Visibility: default
Description: Bounds returns a TRect (261) record with the given origin (ALeft,ATop) and dimensions
(AWidth,AHeight) filled in. The bottom-right corner is calculated by adding AWidth to ALeft
and AHeight to ATop. As a result, a rectangle with width/height set to 0 is exactly 1 pixel.
See also: Rect (277)
4.4.5 CheckSynchronize
Synopsis: Check whether there are any synchronize calls in the synchronize queue.
Declaration: function CheckSynchronize(timeout: LongInt) : Boolean
Visibility: default
Description: CheckSynchronize should be called regularly by the main application thread to handle any
TThread.Synchronize (469) calls that may be waiting for execution by the main thread. If any such
calls are waiting for execution by the main thread, they are executed at once, in the order that they
were scheduled.
The function returns True if any Synchronize method was executed.
TimeOut is the maximum amount of time (in milliseconds) that the CheckSynchronize routine
will wait for synchronisation requests to appear in the queue.
Calling this routine more often will ensure that synchronize requests are handled faster.
This routine may not be called from any thread other than the main thread, as it will execute the
waiting requests.
Threads may call the WakeMainThread (268) to signal the main thread that the synchronisation queue
contains items, and thus speed up the execution of the synchronize calls.
See also: TThread.Synchronize (469), WakeMainThread (268)
269
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.4.6 ClassGroupOf
Synopsis: Returns the class group to which an instance or class belongs
Declaration: function ClassGroupOf(AClass: TPersistentClass) : TPersistentClass
function ClassGroupOf(Instance: TPersistent) : TPersistentClass
Visibility: default
Description: ClassGroupOf returns the class group to which AClass or Instance belongs.
Errors: The result is Nil if no matching class group is found.
See also: StartClassGroup (281), ActivateClassGroup (268), GroupDescendantsWith (249)
4.4.7 CollectionsEqual
Synopsis: Returns True if two collections are equal.
Declaration: function CollectionsEqual(C1: TCollection; C2: TCollection) : Boolean
function CollectionsEqual(C1: TCollection; C2: TCollection;
Owner1: TComponent; Owner2: TComponent)
: Boolean
Visibility: default
Description: CollectionsEqual is not yet implemented. It simply returns False
4.4.8 EndGlobalLoading
Synopsis: Not yet implemented.
Declaration: procedure EndGlobalLoading
Visibility: default
Description: Not yet implemented.
4.4.9 ExtractStrings
Synopsis: Split a string in different words.
Declaration: function ExtractStrings(Separators: TSysCharSet;
WhiteSpace: TSysCharSet; Content: PChar;
Strings: TStrings; AddEmptyStrings: Boolean)
: Integer
Visibility: default
Description: ExtractStrings splits Content (a null-terminated string) into words, and adds the words to
the Strings stringlist. The words are separated by Separators and any characters in whitespace
are stripped from the strings. The space and CR/LF characters are always considered whitespace.
Errors: No length checking is performed on Content. If no null-termination character is present, an access
violation may occur. Likewise, if Strings is not valid, an access violation may occur.
270
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.4.10 FindClass
Synopsis: Returns the class pointer of a class with given name.
Declaration: function FindClass(const AClassName: string) : TPersistentClass
Visibility: default
Description: FindClass searches for the class named ClassName in the list of registered classes and returns a
class pointer to the definition. If no class with the given name could be found, an exception is raised.
The GetClass (272) function does not raise an exception when it does not find the class, but returns a
Nil pointer instead.
See also: RegisterClass (278), GetClass (272)
4.4.11 FindGlobalComponent
Synopsis: Callback used when a component must be found.
Declaration: function FindGlobalComponent(const Name: string) : TComponent
Visibility: default
Description: FindGlobalComponent is a callback of type TFindGlobalComponent (256). It can be set by the
IDE when an unknown reference is found, to offer the user to redirect the link to a new component.
It is a callback used to find a component in a global scope. It is used when the streaming system
needs to find a component which is not part of the component which is currently being streamed. It
should return the component with name Name, or Nil if none is found.
See also: TFindGlobalComponent (256)
4.4.12 FindIdentToInt
Synopsis: Return the string to integer converter for an integer type
Declaration: function FindIdentToInt(AIntegerType: Pointer) : TIdentToInt
Visibility: default
Description: FindIdentToInt returns the handler that handles the conversion of a string representation to an
integer that can be used in component streaming, when IdentToInt (273) is called.
Errors: Nil is returned if no handler is registered for the given type.
4.4.13 FindIntToIdent
Synopsis: Return the integer to string converter for an integer type
Declaration: function FindIntToIdent(AIntegerType: Pointer) : TIntToIdent
Visibility: default
Description: FindIntToIdent returns the handler that handles the conversion of an integer to a string repre-
sentation that can be used in component streaming, when IntToIdent (274) is called.
Errors: Nil is returned if no handler is registered for the given type.
See also: IntToIdent (274), TIntToIdent (258), FindIdentToInt (271)
271
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.4.14 FindNestedComponent
Synopsis: Finds the component with name path starting at the indicated root component.
Declaration: function FindNestedComponent(Root: TComponent; APath: string;
CStyle: Boolean) : TComponent
Visibility: default
Description: FindNestedComponent will descend through the list of owned components (starting at Root)
and will return the component whose name path matches NamePath. As a path separator the char-
acters . (dot), - (dash) and > (greater than) can be used
See also: GlobalFixupReferences (273)
4.4.15 GetClass
Synopsis: Returns the class pointer of a class with given name.
Declaration: function GetClass(const AClassName: string) : TPersistentClass
Visibility: default
Description: GetClass searches for the class named ClassName in the list of registered classes and returns a
class pointer to the definition. If no class with the given name could be found, Nil is returned.
The FindClass (271) function will raise an exception if the does not find the class.
See also: RegisterClass (278), GetClass (272)
4.4.16 GetFixupInstanceNames
Synopsis: Returns the names of elements that need to be resolved for the root component, whose reference
contains ReferenceRootName
Declaration: procedure GetFixupInstanceNames(Root: TComponent;
const ReferenceRootName: string;
Names: TStrings)
Visibility: default
Description: GetFixupInstanceNames examines the list of unresolved references and returns the names of
classes that contain unresolved references to the Root component in the list Names. The list is not
cleared prior to filling it.
See also: GetFixupReferenceNames (272), GlobalFixupReferences (273)
4.4.17 GetFixupReferenceNames
Synopsis: Returns the names of elements that need to be resolved for the root component.
Declaration: procedure GetFixupReferenceNames(Root: TComponent; Names: TStrings)
Visibility: default
Description: GetFixupReferenceNames examines the list of unresolved references and returns the names
of properties that must be resolved for the component Root in the list Names. The list is not cleared
prior to filling it.
See also: GetFixupInstanceNames (272), GlobalFixupReferences (273)
272
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.4.18 GlobalFixupReferences
Synopsis: Called to resolve unresolved references after forms are loaded.
Declaration: procedure GlobalFixupReferences
Visibility: default
Description: GlobalFixupReferences runs over the list of unresolved references and tries to resolve them.
This routine should under normal circumstances not be called in an application programmer’s code.
It is called automatically by the streaming system after a component has been instantiated and its
properties read from a stream. It will attempt to resolve references to other global components.
See also: GetFixupReferenceNames (272), GetFixupInstanceNames (272)
4.4.19 GroupDescendentsWith
Synopsis: Provided for Delphi compatibility
Declaration: procedure GroupDescendentsWith(AClass: TPersistentClass;
AClassGroup: TPersistentClass)
Visibility: default
Description: GroupDescendentsWith exists for Delphi compatibility, it doesn’t actually do anything in Free
Pascal.
See also: RegisterClasses (278)
4.4.20 HexToBin
Synopsis: Convert a hexadecimal string to a binary buffer
Declaration: function HexToBin(HexValue: PChar; BinValue: PChar; BinBufSize: Integer)
: Integer
Visibility: default
Description: HexToBin scans the hexadecimal string representation in HexValue and transforms every 2 char-
acter hexadecimal number to a byte and stores it in BinValue. The buffer size is the size of the
binary buffer. Scanning will stop if the size of the binary buffer is reached or when an invalid char-
acter is encountered. The return value is the number of stored bytes.
Errors: No length checking is done, so if an invalid size is specified, an exception may follow.
See also: BinToHex (269)
4.4.21 IdentToInt
Synopsis: Looks up an integer value in a integer-to-identifier map list.
Declaration: function IdentToInt(const Ident: string; out Int: LongInt;
const Map: Array of TIdentMapEntry) : Boolean
Visibility: default
Description: IdentToInt searches Map for an entry whose Name field matches Ident and returns the corre-
sponding integer value in Int. If a match was found, the function returns True, otherwise, False
is returned.
See also: TIdentToInt (258), TIntToIdent (258), IntToIdent (274), TIdentMapEntry (258)
273
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.4.22 InitComponentRes
Synopsis: Provided for Delphi compatibility only
Declaration: function InitComponentRes(const ResName: string; Instance: TComponent)
: Boolean
Visibility: default
Description: This function is provided for Delphi compatibility. It always returns false.
See also: ReadComponentRes (276)
4.4.23 InitInheritedComponent
Synopsis: Initializes a component descending from RootAncestor
Declaration: function InitInheritedComponent(Instance: TComponent;
RootAncestor: TClass) : Boolean
Visibility: default
Description: InitInheritedComponent should be called from a constructor to read properties of the com-
ponent Instance from the streaming system. The RootAncestor class is the root class from
which Instance is a descendant. This must be one of TDatamodule, TCustomForm or TFrame.
The function returns True if the properties were successfully read from a stream or False if some
error occurred.
See also: ReadComponentRes (276), ReadComponentResEx (277), ReadComponentResFile (277)
4.4.24 IntToIdent
Synopsis: Looks up an identifier for an integer value in a identifier-to-integer map list.
Declaration: function IntToIdent(Int: LongInt; var Ident: string;
const Map: Array of TIdentMapEntry) : Boolean
Visibility: default
Description: IdentToInt searches Map for an entry whose Value field matches Int and returns the corre-
sponding identifier in Ident. If a match was found, the function returns True, otherwise, False
is returned.
See also: TIdentToInt (258), TintToIdent (258), IdentToInt (273), TIdentMapEntry (258)
4.4.25 InvalidPoint
Synopsis: Check whether a point is invalid.
Declaration: function InvalidPoint(X: Integer; Y: Integer) : Boolean
function InvalidPoint(const At: TPoint) : Boolean
function InvalidPoint(const At: TSmallPoint) : Boolean
Visibility: default
Description: InvalidPoint returns True if the X and Y coordinates (of the TPoint or TSmallPoint
records, if one of these versions is used) are -1.
See also: TPoint (260), TSmallPoint (263), PointsEqual (276)
274
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.4.26 LineStart
Synopsis: Finds the start of a line in Buffer before BufPos.
Declaration: function LineStart(Buffer: PChar; BufPos: PChar) : PChar
Visibility: default
Description: LineStart reversely scans Buffer starting at BufPos for a linefeed character. It returns a
pointer at the linefeed character.
4.4.27 NotifyGlobalLoading
Synopsis: Not yet implemented.
Declaration: procedure NotifyGlobalLoading
Visibility: default
Description: Not yet implemented.
4.4.28 ObjectBinaryToText
Synopsis: Converts an object stream from a binary to a text format.
Declaration: procedure ObjectBinaryToText(Input: TStream; Output: TStream;
Encoding: TObjectTextEncoding)
procedure ObjectBinaryToText(Input: TStream; Output: TStream)
Visibility: default
Description: ObjectBinaryToText reads an object stream in binary format from Input and writes the
object stream in text format to Output. No components are instantiated during the process, this is a
pure conversion routine.
See also: ObjectTextToBinary (275)
4.4.29 ObjectResourceToText
Synopsis: Converts an object stream from a (windows) resource to a text format.
Declaration: procedure ObjectResourceToText(Input: TStream; Output: TStream)
Visibility: default
Description: ObjectResourceToText reads the resource header from the Input stream and then passes the
streams to ObjectBinaryToText (275)
See also: ObjectBinaryToText (275), ObjectTextToResource (276)
4.4.30 ObjectTextToBinary
Synopsis: Converts an object stream from a text to a binary format.
Declaration: procedure ObjectTextToBinary(Input: TStream; Output: TStream)
Visibility: default
Description: Converts an object stream from a text to a binary format.
275
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.4.31 ObjectTextToResource
Synopsis: Converts an object stream from a text to a (windows) resource format.
Declaration: procedure ObjectTextToResource(Input: TStream; Output: TStream)
Visibility: default
Description: ObjectTextToResource reads an object stream in text format from Input and writes a re-
source stream to Output.
Note that for the current implementation of this method in Free Pascal, the output stream should
support positioning. (e.g. it should not be a pipe)
See also: ObjectBinaryToText (275), ObjectResourceToText (275)
4.4.32 Point
Synopsis: Returns a TPoint record with the given coordinates.
Declaration: function Point(AX: Integer; AY: Integer) : TPoint
Visibility: default
Description: Point returns a TPoint (260) record with the given coordinates AX and AY filled in.
See also: TPoint (260), SmallPoint (281), Rect (277), Bounds (269)
4.4.33 PointsEqual
Synopsis: Check whether two TPoint variables are equal.
Declaration: function PointsEqual(const P1: TPoint; const P2: TPoint) : Boolean
function PointsEqual(const P1: TSmallPoint; const P2: TSmallPoint)
: Boolean
Visibility: default
Description: PointsEqual compares the P1 and P2 points (of type TPoint (260) or TSmallPoint (263)) and
returns True if the X and Y coordinates of the points are equal, or False otherwise.
See also: TPoint (260), TSmallPoint (263), InvalidPoint (274)
4.4.34 ReadComponentRes
Synopsis: Read component properties from a resource in the current module
Declaration: function ReadComponentRes(const ResName: string; Instance: TComponent)
: TComponent
Visibility: default
Description: ReadComponentRes will read the component’s properties from the resource ResName in the
current module (always program module). It returns Nil if the resource was not found. It returns
Instance if the resource was found and successfully applied to the component.
Errors: The function may raise an exception if the stream contains wrong data.
See also: ReadComponentResEx (277)
276
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.4.35 ReadComponentResEx
Synopsis: Read component properties from a resource in the specified module
Declaration: function ReadComponentResEx(HInstance: THandle; const ResName: string)
: TComponent
Visibility: default
Description: ReadComponentRes will locate the resource ResName in instance HInstance (the current
program, normally). It returns Nil if the resource was not found. It returns an instantiated compo-
nent with all properties found in the stream, applied. This requires that the component is registered
using registerclass.
Errors: The function may raise an exception if the stream contains wrong data.
See also: ReadComponentRes (276)
4.4.36 ReadComponentResFile
Synopsis: Read component properties from a specified resource file
Declaration: function ReadComponentResFile(const FileName: string;
Instance: TComponent) : TComponent
Visibility: default
Description: ReadComponentResFile starts reading properties for Instance from the file FileName. It
creates a filestream from FileName and then calls the TStream.ReadComponentRes (431) method
to read the state of the component from the stream.
See also: TStream.ReadComponentRes (431), WriteComponentResFile (282)
4.4.37 Rect
Synopsis: Returns a TRect record with the given coordinates.
Declaration: function Rect(ALeft: Integer; ATop: Integer; ARight: Integer;
ABottom: Integer) : TRect
Visibility: default
Description: Rect returns a TRect (261) record with the given top-left (ALeft,ATop) and bottom-right
(ABottom,ARight) corners filled in.
No checking is done to see whether the coordinates are valid.
See also: TRect (261), Point (276), SmallPoint (281), Bounds (269)
4.4.38 RedirectFixupReferences
Synopsis: Redirects references under the root object from OldRootName to NewRootName
Declaration: procedure RedirectFixupReferences(Root: TComponent;
const OldRootName: string;
const NewRootName: string)
Visibility: default
277
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
Description: RedirectFixupReferences examines the list of unresolved references and replaces refer-
ences to a root object named OldRootName with references to root object NewRootName.
An application programmer should never need to call RedirectFixupReferences. This func-
tion can be used by an IDE to support redirection of broken component links.
See also: RemoveFixupReferences (280)
4.4.39 RegisterClass
Synopsis: Registers a class with the streaming system.
Declaration: procedure RegisterClass(AClass: TPersistentClass)
Visibility: default
Description: RegisterClass registers the class AClass in the streaming system. After the class has been
registered, it can be read from a stream when a reference to this class is encountered.
See also: RegisterClasses (278), RegisterClassAlias (278), RegisterComponents (278), UnregisterClass (281)
4.4.40 RegisterClassAlias
Synopsis: Registers a class alias with the streaming system.
Declaration: procedure RegisterClassAlias(AClass: TPersistentClass;
const Alias: string)
Visibility: default
Description: RegisterClassAlias registers a class alias in the streaming system. If a reference to a class
Alias is encountered in a stream, then an instance of the class AClass will be created instead by
the streaming code.
See also: RegisterClass (278), RegisterClasses (278), RegisterComponents (278), UnregisterClass (281)
4.4.41 RegisterClasses
Synopsis: Registers multiple classes with the streaming system.
Declaration: procedure RegisterClasses(AClasses: Array of TPersistentClass)
Visibility: default
Description: RegisterClasses registers the specified classes AClass in the streaming system. After the
classes have been registered, they can be read from a stream when a reference to this class is encoun-
tered.
See also: RegisterClass (278), RegisterClassAlias (278), RegisterComponents (278), UnregisterClass (281)
4.4.42 RegisterComponents
Synopsis: Registers components for the component palette.
Declaration: procedure RegisterComponents(const Page: string;
ComponentClasses: Array of TComponentClass)
Visibility: default
278
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
Description: RegisterComponents registers the component on the appropriate component page. The com-
ponent pages can be used by an IDE to display the known components so an application programmer
may pick and use the components in his programs.
Registercomponents inserts the component class in the correct component page. If the RegisterComponentsProc
procedure is set, this is called as well. Note that this behaviour is different from Delphi’s behaviour
where an exception will be raised if the procedural variable is not set.
See also: RegisterClass (278), RegisterNoIcon (280)
4.4.43 RegisterFindGlobalComponentProc
Synopsis: Register a component searching handler
Declaration: procedure RegisterFindGlobalComponentProc
(AFindGlobalComponent: TFindGlobalComponent)
Visibility: default
Description: RegisterFindGlobalComponentProc registers a global component search callback AFindGlobalComponent.
When FindGlobalComponent (271) is called, then this callback will be used to search for the com-
ponent.
Errors: None.
See also: FindGlobalComponent (271), UnRegisterFindGlobalComponentProc (282)
4.4.44 RegisterInitComponentHandler
Synopsis: Register a component initialization handler
Declaration: procedure RegisterInitComponentHandler(ComponentClass: TComponentClass;
Handler: TInitComponentHandler)
Visibility: default
Description: RegisterInitComponentHandler registers a component initialization handler Handler
for the component ComponentClass. This handler will be used to initialize descendants of
ComponentClass in the InitInheritedComponent (274) call.
See also: InitInheritedComponent (274), TInitComponentHandler (258)
4.4.45 RegisterIntegerConsts
Synopsis: Registers some integer-to-identifier mappings.
Declaration: procedure RegisterIntegerConsts(IntegerType: Pointer;
IdentToIntFn: TIdentToInt;
IntToIdentFn: TIntToIdent)
Visibility: default
Description: RegisterIntegerConsts registers a pair of callbacks to be used when an integer of type
IntegerType must be mapped to an identifier (using IntToIdentFn) or when an identifier
must be mapper to an integer (using IdentToIntFn).
Component programmers can use RegisterIntegerConsts to associate a series of identifier
strings with integer values for a property. A necessary condition is that the property should have a
279
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
separate type declared using the type integer syntax. If a type of integer is defined in this way,
an IDE can show symbolic names for the values of these properties.
The IntegerType should be a pointer to the type information of the integer type. The IntToIdentFn
and IdentToIntFn are two callbacks that will be used when converting between the identifier and
integer value and vice versa. The functions IdentToInt (273) and IntToIdent (274) can be used to
implement these callback functions.
See also: TIdentToInt (258), TIntToIdent (258), IdentToInt (273), IntToIdent (274)
4.4.46 RegisterNoIcon
Synopsis: Registers components that have no icon on the component palette.
Declaration: procedure RegisterNoIcon(ComponentClasses: Array of TComponentClass)
Visibility: default
Description: RegisterNoIcon performs the same function as RegisterComponents (278) except that it calls
RegisterNoIconProc (268) instead of RegisterComponentsProc (267)
See also: RegisterNoIconProc (268), RegisterComponents (278)
4.4.47 RegisterNonActiveX
Synopsis: Register non-activex component.
Declaration: procedure RegisterNonActiveX
(ComponentClasses: Array of TComponentClass;
AxRegType: TActiveXRegType)
Visibility: default
Description: Not yet implemented in Free Pascal
4.4.48 RemoveFixupReferences
Synopsis: Removes references to rootname from the fixup list.
Declaration: procedure RemoveFixupReferences(Root: TComponent;
const RootName: string)
Visibility: default
Description: RemoveFixupReferences examines the list of unresolved references and removes references
to a root object pointing at Root or a root component named RootName.
An application programmer should never need to call RemoveFixupReferences. This function
can be used by an IDE to support removal of broken component links.
See also: RedirectFixupReferences (277)
280
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.4.49 RemoveFixups
Synopsis: Removes Instance from the fixup list.
Declaration: procedure RemoveFixups(Instance: TPersistent)
Visibility: default
Description: RemoveFixups removes all entries for component Instance from the list of unresolved refer-
ences.a
See also: RedirectFixupReferences (277), RemoveFixupReferences (280)
4.4.50 SmallPoint
Synopsis: Returns a TSmallPoint record with the given coordinates.
Declaration: function SmallPoint(AX: SmallInt; AY: SmallInt) : TSmallPoint
Visibility: default
Description: SmallPoint returns a TSmallPoint (263) record with the given coordinates AX and AY filled in.
See also: TSmallPoint (263), Point (276), Rect (277), Bounds (269)
4.4.51 StartClassGroup
Synopsis: Start new class group.
Declaration: procedure StartClassGroup(AClass: TPersistentClass)
Visibility: default
Description: StartClassGroup starts a new class group and adds AClass to it.
The class registration and streaming mechanism allows to organize the classes in groups. This allows
an IDE to form groups of classes, which can be enabled or disabled. It is not needed at Run-Time.
See also: GroupDescendantsWith (249), ActivateClassGroup (268), ClassGroupOf (270)
4.4.52 UnRegisterClass
Synopsis: Unregisters a class from the streaming system.
Declaration: procedure UnRegisterClass(AClass: TPersistentClass)
Visibility: default
Description: UnregisterClass removes the class AClass from the class definitions in the streaming system.
See also: UnRegisterClasses (281), UnRegisterModuleClasses (282), RegisterClass (278)
4.4.53 UnRegisterClasses
Synopsis: Unregisters multiple classes from the streaming system.
Declaration: procedure UnRegisterClasses(AClasses: Array of TPersistentClass)
Visibility: default
Description: UnregisterClasses removes the classes in AClasses from the class definitions in the stream-
ing system.
281
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.4.54 UnregisterFindGlobalComponentProc
Synopsis: Remove a previously registered component searching handler.
Declaration: procedure UnregisterFindGlobalComponentProc
(AFindGlobalComponent: TFindGlobalComponen
Visibility: default
Description: UnRegisterFindGlobalComponentProc unregisters the previously registered global com-
ponent search callback AFindGlobalComponent. After this call, when FindGlobalComponent
(271) is called, then this callback will be no longer be used to search for the component.
Errors: None.
See also: FindGlobalComponent (271), RegisterFindGlobalComponentProc (279)
4.4.55 UnRegisterModuleClasses
Synopsis: Unregisters classes registered by module.
Declaration: procedure UnRegisterModuleClasses(Module: HMODULE)
Visibility: default
Description: UnRegisterModuleClasses unregisters all classes which reside in the module Module. For
each registered class, the definition pointer is checked to see whether it resides in the module, and if
it does, the definition is removed.
See also: UnRegisterClass (281), UnRegisterClasses (281), RegisterClasses (278)
4.4.56 WriteComponentResFile
Synopsis: Write component properties to a specified resource file
Declaration: procedure WriteComponentResFile(const FileName: string;
Instance: TComponent)
Visibility: default
Description: WriteComponentResFile starts writing properties of Instance to the file FileName. It
creates a filestream from FileName and then calls TStream.WriteComponentRes (432) method to
write the state of the component to the stream.
See also: TStream.WriteComponentRes (432), ReadComponentResFile (277)
4.5 EBitsError
4.5.1 Description
When an index of a bit in a TBits (331) is out of the valid range (0 to Count-1) then a EBitsError
exception is raised.
282
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.6 EClassNotFound
4.6.1 Description
When the streaming system needs to create a component, it looks for the class pointer (VMT) in the
list of registered classes by its name. If this name is not found, then an EClassNotFound is raised.
See also: EFilerError (283)
4.7 EComponentError
4.7.1 Description
When an error occurs during the registration of a component, or when naming a component, then a
EComponentError is raised. Possible causes are:
1. An name with an illegal character was assigned to a component.
2. A component with the same name and owner already exists.
3. The component registration system isn’t set up properly.
See also: TComponent (348), TComponent.Name (358)
4.8 EFCreateError
4.8.1 Description
When the operating system reports an error during creation of a new file in the Filestream Constructor
(368), a EFCreateError is raised.
See also: EStreamError (285), EFOpenError (283)
4.9 EFilerError
4.9.1 Description
This class serves as an ancestor class for exceptions that are raised when an error occurs during
component streaming. A EFilerError exception is raised when a class is registered twice.
See also: EStreamError (285), EReadError (285)
4.10 EFOpenError
4.10.1 Description
When the operating system reports an error during the opening of a file in the Filestream Constructor
(368), a EFOpenError is raised.
See also: EStreamError (285), EFCreateError (283)
283
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.11 EInvalidImage
4.11.1 Description
This exception is not used by Free Pascal but is provided for Delphi compatibility.
4.12 EInvalidOperation
4.12.1 Description
This exception is not used in Free Pascal, it is defined for Delphi compatibiliy purposes only.
4.13 EListError
4.13.1 Description
If an error occurs in one of the TList (388) or TStrings (447) methods, then a EListError excep-
tion is raised. This can occur in one of the following cases:
1. There is not enough memory to expand the list.
2. The list tried to grow beyond its maximal capacity.
3. An attempt was made to reduce the capacity of the list below the current element count.
4. An attempt was made to set the list count to a negative value.
5. A non-existent element of the list was referenced. (i.e. the list index was out of bounds)
6. An attempt was made to move an item to a position outside the list’s bounds.
See also: TList (388), TStrings (447)
4.14 EMethodNotFound
4.14.1 Description
This exception is no longer used in the streaming system. This error is replaced by a EReadError
(285).
See also: EFilerError (283), EReadError (285)
4.15 EObserver
4.15.1 Description
EObserver is an error that is raised when an object is registered as an observer, and it does not
implement the IFPObserver (289) interface.
See also: IFPObserver (289), IFPObserved.FPOAttachObserver (288)
284
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.16 EOutOfResources
4.16.1 Description
This exception is not used in Free Pascal, it is defined for Delphi compatibiliy purposes only.
4.17 EParserError
4.17.1 Description
When an error occurs during the parsing of a stream, an EParserError is raised. Usually this
indicates that an invalid token was found on the input stream, or the token read from the stream
wasn’t the expected token.
See also: TParser (401)
4.18 EReadError
4.18.1 Description
If an error occurs when reading from a stream, a EReadError exception is raised. Possible causes
for this are:
1. Not enough data is available when reading from a stream
2. The stream containing a component’s data contains invalid data. this will occurr only when
reading a component from a stream.
See also: EFilerError (283), EWriteError (286)
4.19 EResNotFound
4.19.1 Description
This exception is not used by Free Pascal but is provided for Delphi compatibility.
4.20 EStreamError
4.20.1 Description
An EStreamError is raised when an error occurs during reading from or writng to a stream:
Possible causes are
1. Not enough data is available in the stream.
2. Trying to seek beyond the beginning or end of the stream.
3. Trying to set the capacity of a memory stream and no memory is available.
4. Trying to write to a read-only stream, such as a resource stream.
5. Trying to read from a write-only stream.
See also: EFCreateError (283)
285
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.21 EStringListError
4.21.1 Description
When an error occurs in one of the methods of TStrings (447) then an EStringListError is
raised. This can have one of the following causes:
1. There is not enough memory to expand the list.
2. The list tried to grow beyond its maximal capacity.
3. A non-existent element of the list was referenced. (i.e. the list index was out of bounds)
4. An attempt was made to add a duplicate entry to a TStringList (442) when TStringList.Duplicates
(445) is False.
See also: TStrings (447), TStringList (442)
4.22 EThread
4.22.1 Description
Thread error exception.
4.23 EThreadDestroyCalled
4.23.1 Description
Exception raised when a thread is destroyed illegally.
4.24 EThreadExternalException
4.24.1 Description
EThreadExternalException is raised by for example TThread.CheckTerminated (470) and
TThread.SetReturnValue (470) when the thread was not created by the Free Pascal program, but by
an external code base (for example a DLL, or the calling application in a DLL).
See also: TThread.CheckTerminated (470), TThread.SetReturnValue (470)
4.25 EWriteError
4.25.1 Description
If an error occurs when writing to a stream, a EWriteError exception is raised. Possible causes
for this are:
1. The stream doesn’t allow writing.
2. An error occurred when writing a property to a stream.
See also: EFilerError (283), EReadError (285)
286
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.26 IDesignerNotify
4.26.1 Description
IDesignerNotify is an interface that can be used to communicate changes to a designer mech-
anism. It offers functionality for detecting changes, and notifications when the component is de-
stroyed.
4.26.2 Method overview
Page Method Description
287 Modified Notify that the component is modified.
287 Notification Notification of owner changes
4.26.3 IDesignerNotify.Modified
Synopsis: Notify that the component is modified.
Declaration: procedure Modified
Visibility: default
Description: Modified can be used to notify a designer of changes, indicating that components should be
streamed.
4.26.4 IDesignerNotify.Notification
Synopsis: Notification of owner changes
Declaration: procedure Notification(AnObject: TPersistent; Operation: TOperation)
Visibility: default
Description: Notification is the interface counterpart of TComponent.Notification (350) which is used to
communicate adds to the components.
See also: TComponent.Notification (350)
4.27 IFPObserved
4.27.1 Description
IFPObserved is an interface which can be implemented in objects that must be observable. Ob-
jects that wish to observe the object can register themselves with the FPOAttachObserver (249) call,
and must be detached using the FPODetachObserver (249) call.
This interface is not reference counted, so care must be taken that the ooFree message is sent with
FPONotifyObservers (249) when the object is freed.
See also: FPONotifyObservers (249)
287
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.27.2 Method overview
Page Method Description
288 FPOAttachObserver Attach a new observer to the object
288 FPODetachObserver Remove an observer from the list of observers.
288 FPONotifyObservers Notify all observers
4.27.3 IFPObserved.FPOAttachObserver
Synopsis: Attach a new observer to the object
Declaration: procedure FPOAttachObserver(AObserver: TObject)
Visibility: default
Description: FPOAttachObserver must be called with an object instance AObserver that implements the
IFPObserver (289) interface. The FPOObservedChanged (289) method of the interface will be called
whenever FPONotifyObservers (249) is used to notify observers of a change. Objects implementing
this interface should check that AObserver actually implements the IFPObserver (289) interface.
Do not make assumptions on how the interface behaves if FPOAttachObserver is called more
than once with the same interface. It may add the object to the list of observers unconditionally (in
which case it will be notified twice) or it may check that it is not yet in the list.
Errors: If AObserver does not implement the IFPObserver (289) interface, an EObserver (284) exception
must be raised. No other errors should be raised, other than a possible out of memory error.
See also: IFPObserver (289), FPOObservedChanged (289), FPONotifyObservers (249)
4.27.4 IFPObserved.FPODetachObserver
Synopsis: Remove an observer from the list of observers.
Declaration: procedure FPODetachObserver(AObserver: TObject)
Visibility: default
Description: FPODetachObserver removes the AObserver object from the list of observers. If it was not
in the list, then this is silently accepted. Once removed, it will no longer receive notifications when
FPOObservedChanged (289) is called.
If the object was added more than once using FPOAttachObserver (249), then it depends on the
implementor of the interface whether or FPODetachObserver must be called an equal number
of times.
See also: IFPObserver (289), FPOObservedChanged (289), FPONotifyObservers (249), FPOAttachObserver
(249)
4.27.5 IFPObserved.FPONotifyObservers
Synopsis: Notify all observers
Declaration: procedure FPONotifyObservers(ASender: TObject;
AOperation: TFPObservedOperation;
Data: Pointer)
Visibility: default
288
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
Description: FPONotifyObservers notifies all observers of the object that a change has occurred. It calls
FPOObservedChanged (289) on the IFPObserver (289) interface of all attached objects, and passes
on ASender (normally this is Self), AOperation and Data. What Data is, depends on the
implementor of the interface.
There is no guaranteed order in which the change notifications are delivered to the observers. This is
an implementation-specific detail, which should not be relied upon in any way.
See also: IFPObserver (289), FPOObservedChanged (289), FPODetachObserver (249), FPOAttachObserver
(249)
4.28 IFPObserver
4.28.1 Description
IFPObserver is the interface an object must implement if it wishes to receive change notifications
from another object. The presence of this interface will be checked when the object registers itself
using IFPObserver.FPOAttachObserver (289). The change notifications arrive because the FPOOb-
servedChanged (249) method is called by the observed object.
See also: IFPObserved (287), FPOAttachObserver (288)
4.28.2 Method overview
Page Method Description
289 FPOObservedChanged Entry point for change notifications
4.28.3 IFPObserver.FPOObservedChanged
Synopsis: Entry point for change notifications
Declaration: procedure FPOObservedChanged(ASender: TObject;
Operation: TFPObservedOperation;
Data: Pointer)
Visibility: default
Description: FPOObservedChanged is the method that is called by an observed object (IFPObserved (287))
when it calls FPONotifyObservers (288) The Sender is the object under observation, the Operation
and Data are the parameters used in the call to FPONotifyObservers.
See also: IFPObserved (287), FPONotifyObservers (288)
4.29 IInterfaceComponentReference
4.29.1 Description
IInterfaceComponentReference is an interface to return the component that implements a
given interface. It is implemented by TComponent (348).
See also: TComponent (348)
289
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.29.2 Method overview
Page Method Description
290 GetComponent Return component instance
4.29.3 IInterfaceComponentReference.GetComponent
Synopsis: Return component instance
Declaration: function GetComponent : TComponent
Visibility: default
Description: GetComponent returns the component instance.
Errors: None.
See also: TComponent (348)
4.30 IInterfaceList
4.30.1 Description
IInterfaceList is an interface for maintaining a list of interfaces, strongly resembling the stan-
dard TList (388) class. It offers the same list of public methods as TList, with the exception that it
uses interfaces instead of pointers.
All interfaces in the list should descend from IUnknown.
More detailed descriptions of how the various methods behave can be found in the TList reference.
See also: TList (388)
4.30.2 Method overview
Page Method Description
293 Add Add an interface to the list
292 Clear Clear the list
292 Delete Remove an interface from the list
293 Exchange Exchange 2 interfaces in the list
293 First Return the first non-empty interface in the list.
291 Get Retrieve an interface pointer from the list.
291 GetCapacity Return the capacity of the list.
291 GetCount Return the current number of elements in the list.
293 IndexOf Return the index of an interface.
293 Insert Insert an interface in the list.
294 Last Returns the last non-nil interface in the list.
294 Lock Lock the list
291 Put Write an item to the list
294 Remove Remove an interface from the list
292 SetCapacity Set the capacity of the list
292 SetCount Set the number of items in the list
294 Unlock Unlock the list.
290
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.30.3 Property overview
Page Properties Access Description
294 Capacity rw Capacity of the list
295 Count rw Current number of elements in the list.
295 Items rw Provides Index-based, sequential, access to the interfaces in the
list.
4.30.4 IInterfaceList.Get
Synopsis: Retrieve an interface pointer from the list.
Declaration: function Get(i: Integer) : IUnknown
Visibility: default
Description: Get returns the interface pointer at position i in the list. It serves as the Read method for the Items
(295) property.
See also: IInterfaceList.Items (295), TList.Items (395)
4.30.5 IInterfaceList.GetCapacity
Synopsis: Return the capacity of the list.
Declaration: function GetCapacity : Integer
Visibility: default
Description: GetCapacity returns the current capacity of the list. It serves as the Read method for the Capac-
ity (294) property.
See also: IInterfaceList.Capacity (294), TList.Capacity (395)
4.30.6 IInterfaceList.GetCount
Synopsis: Return the current number of elements in the list.
Declaration: function GetCount : Integer
Visibility: default
Description: It serves as the Read method for the Count (295) property.
See also: IInterfaceList.Count (295), TList.Count (395)
4.30.7 IInterfaceList.Put
Synopsis: Write an item to the list
Declaration: procedure Put(i: Integer; item: IUnknown)
Visibility: default
Description: Put writes the interface Item at position I in the list. It servers as the Write method for the Items
(295) property.
See also: IInterfaceList.Items (295), TList.Items (395)
291
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.30.8 IInterfaceList.SetCapacity
Synopsis: Set the capacity of the list
Declaration: procedure SetCapacity(NewCapacity: Integer)
Visibility: default
Description: SetCapacity sets the capacity of the list to NewCapacity. It serves as the Write method for
the Capacity (294) property.
See also: IInterfaceList.Capacity (294), TList.Capacity (395)
4.30.9 IInterfaceList.SetCount
Synopsis: Set the number of items in the list
Declaration: procedure SetCount(NewCount: Integer)
Visibility: default
Description: SetCount sets the count of the list to NewCount. It serves as the Write method for the Capacity
(294)
See also: IInterfaceList.Count (295), TList.Count (395)
4.30.10 IInterfaceList.Clear
Synopsis: Clear the list
Declaration: procedure Clear
Visibility: default
Description: Clear removes all interfaces from the list. All interfaces in the list will be cleared (i.e. their
reference count will decrease with 1)
See also: TList.Clear (391)
4.30.11 IInterfaceList.Delete
Synopsis: Remove an interface from the list
Declaration: procedure Delete(index: Integer)
Visibility: default
Description: Delete removes the interface at position Index from the list. It does this by explicitly clearing
the interface and then removing the slot.
See also: TList.Clear (391), IInterfaceList.Add (293), IInterfaceList.Delete (292), IInterfaceList.Insert (293)
292
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.30.12 IInterfaceList.Exchange
Synopsis: Exchange 2 interfaces in the list
Declaration: procedure Exchange(index1: Integer; index2: Integer)
Visibility: default
Description: Exchange exchanges 2 interfaces in the list at locations index1 and Index2.
See also: TList.Exchange (391), IInterfaceList.Add (293), IInterfaceList.Delete (292), IInterfaceList.Insert
(293)
4.30.13 IInterfaceList.First
Synopsis: Return the first non-empty interface in the list.
Declaration: function First : IUnknown
Visibility: default
Description: First returns the first non-empty interface in the list.
See also: TList.First (392), IInterfaceList.IndexOf (293), IInterfaceList.Last (294)
4.30.14 IInterfaceList.IndexOf
Synopsis: Return the index of an interface.
Declaration: function IndexOf(item: IUnknown) : Integer
Visibility: default
Description: IndexOf returns the location in the list of the interface Item. If there is no such interface in the
list, then -1 is returned.
See also: TList.IndexOf (393), IInterfaceList.First (293), IInterfaceList.Last (294)
4.30.15 IInterfaceList.Add
Synopsis: Add an interface to the list
Declaration: function Add(item: IUnknown) : Integer
Visibility: default
Description: Add adds the interface Item to the list, and returns the position at which it has been added.
See also: TList.Add (390), IInterfaceList.Insert (293), IInterfaceList.Delete (292)
4.30.16 IInterfaceList.Insert
Synopsis: Insert an interface in the list.
Declaration: procedure Insert(i: Integer; item: IUnknown)
Visibility: default
Description: Insert inserts the interface Item in the list, at position I, shifting all items one position.
See also: TList.Insert (393), IInterfaceList.Add (293), IInterfaceList.Delete (292)
293
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.30.17 IInterfaceList.Last
Synopsis: Returns the last non-nil interface in the list.
Declaration: function Last : IUnknown
Visibility: default
Description: Last returns the last non-empty interface in the list.
See also: TList.Last (393), IInterfaceList.First (293), IInterfaceList.IndexOf (293)
4.30.18 IInterfaceList.Remove
Synopsis: Remove an interface from the list
Declaration: function Remove(item: IUnknown) : Integer
Visibility: default
Description: Remove searches for the first occurrence of Item in the list and deletes it.
See also: TList.Remove (394), IInterfaceList.Delete (292), IInterfaceList.IndexOf (293)
4.30.19 IInterfaceList.Lock
Synopsis: Lock the list
Declaration: procedure Lock
Visibility: default
Description: Lock locks the list. After a call to lock, the object list can only be accessed by the current thread,
untill UnLock (294) is called.
See also: TInterfaceList.Lock (385), IInterfaceList.Unlock (294)
4.30.20 IInterfaceList.Unlock
Synopsis: Unlock the list.
Declaration: procedure Unlock
Visibility: default
Description: Unlock unlocks a locked list. After a call to UnLock, other threads are again able to access the
list.
See also: TInterfaceList.UnLock (385), IInterfaceList.Lock (294)
4.30.21 IInterfaceList.Capacity
Synopsis: Capacity of the list
Declaration: Property Capacity : Integer
Visibility: default
Access: Read,Write
294
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
Description: Capacity is the maximum number of elements the list can hold without needing to reallocate
memory for the list. It can be set to improve speed when adding a lot of items to the list.
See also: TList.Capacity (395), IInterfaceList.Count (295)
4.30.22 IInterfaceList.Count
Synopsis: Current number of elements in the list.
Declaration: Property Count : Integer
Visibility: default
Access: Read,Write
Description: Count is the current number of elements in the list. Setting it to a larger number will allocate empty
slots. Setting it to a smaller number will clear any interfaces that fall outside the new border.
See also: IInterfaceList.Capacity (294), TList.Count (395)
4.30.23 IInterfaceList.Items
Synopsis: Provides Index-based, sequential, access to the interfaces in the list.
Declaration: Property Items[index: Integer]: IUnknown; default
Visibility: default
Access: Read,Write
Description: Items is the default property of the interface list and provides index-based array access to the
interfaces in the list. Allowed values for Index include 0 to Count-1
See also: IInterfaceList.Count (295), TList.Items (395)
4.31 IStreamPersist
4.31.1 Description
IStreamPersist defines an interface for object persistence streaming to a stream. Any class
implementing this interface is expected to be able to save or load it’s state from or to a stream.
See also: TPersistent (408), TComponent (348), TStream (427)
4.31.2 Method overview
Page Method Description
296 LoadFromStream Load persistent data from stream.
296 SaveToStream Save persistent data to stream.
295
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.31.3 IStreamPersist.LoadFromStream
Synopsis: Load persistent data from stream.
Declaration: procedure LoadFromStream(Stream: TStream)
Visibility: default
Description: LoadFromStream is the method called when the object should load it’s state from the stream
stream. It should be able to read the data which was written using the SavetoStream method.
See also: TPersistent (408), TComponent (348), TStream (427), IStreamPersist.SaveToStream (296)
4.31.4 IStreamPersist.SaveToStream
Synopsis: Save persistent data to stream.
Declaration: procedure SaveToStream(Stream: TStream)
Visibility: default
Description: SaveFromStream is the method called when the object should load it’s state from the stream
stream. The data written by this method should be readable by the LoadFromStream method.
See also: TPersistent (408), TComponent (348), TStream (427), IStreamPersist.LoadFromStream (296)
4.32 IStringsAdapter
4.32.1 Description
Is not yet supported in Free Pascal.
See also: TStrings (447)
4.32.2 Method overview
Page Method Description
296 ReferenceStrings Add a reference to the indicated strings.
296 ReleaseStrings Release the reference to the strings.
4.32.3 IStringsAdapter.ReferenceStrings
Synopsis: Add a reference to the indicated strings.
Declaration: procedure ReferenceStrings(S: TStrings)
Visibility: default
4.32.4 IStringsAdapter.ReleaseStrings
Synopsis: Release the reference to the strings.
Declaration: procedure ReleaseStrings
Visibility: default
296
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.33 IVCLComObject
4.33.1 Description
IVCLComObject is used by TComponent to implement the IUnknown interface used by COM
automation servers. Partially, it is the translation to pascal of the IDispatch interface definition by
Microsoft. If TComponent needs to return an IUnknown interface, it creates a IVCLComObject
interface instead.
See also: TComponent.VCLComObject (358)
4.33.2 Method overview
Page Method Description
298 FreeOnRelease Is called by TComponent.FreeOnRelease
298 GetIDsOfNames The IDispatch:GetIDsOfNames call for automation servers.
297 GetTypeInfo The IDispatch:GetTypeInfo call for automation servers
297 GetTypeInfoCount The IDispatch:GetTypeInfoCount call for automation servers
298 Invoke The IDispatch:Invoke call for automation servers.
298 SafeCallException This method can be invoked if an exception occurs during Invoke
4.33.3 IVCLComObject.GetTypeInfoCount
Synopsis: The IDispatch:GetTypeInfoCount call for automation servers
Declaration: function GetTypeInfoCount(out Count: Integer) : HRESULT
Visibility: default
Description: GetTypeInfoCount must return in Count either 0 or 1 to indicate that it provides type infor-
mation (1) or not (0).
Errors: On error, a nonzero (different from S_OK) return value must be returned.
See also: IVCLComObject.GetTypeInfo (297)
4.33.4 IVCLComObject.GetTypeInfo
Synopsis: The IDispatch:GetTypeInfo call for automation servers
Declaration: function GetTypeInfo(Index: Integer; LocaleID: Integer; out TypeInfo)
: HRESULT
Visibility: default
Description: GetTypeInfo must return the Index-th entry in the type information of the component in TypeInfo.
The LocaleID argument can be used to indicate the locale of the caller, as different type informa-
tion can be returned depending on the locale.
Errors: On error, a nonzero (different from S_OK) return value must be returned.
See also: IVCLComObject.GetTypeInfoCount (297)
297
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.33.5 IVCLComObject.GetIDsOfNames
Synopsis: The IDispatch:GetIDsOfNames call for automation servers.
Declaration: function GetIDsOfNames(const IID: TGuid; Names: Pointer;
NameCount: Integer; LocaleID: Integer;
DispIDs: Pointer) : HRESULT
Visibility: default
Description: GetIDsOfNames must return in DispIDs the dispatch Ids for the NameCount names of the
methods listed in Names. The LocaleID indicates the locale of the caller.
Errors: On error, a nonzero (different from S_OK) return value must be returned.
See also: IVCLComObject.Invoke (298)
4.33.6 IVCLComObject.Invoke
Synopsis: The IDispatch:Invoke call for automation servers.
Declaration: function Invoke(DispID: Integer; const IID: TGuid; LocaleID: Integer;
Flags: Word; var Params; VarResult: Pointer;
ExcepInfo: Pointer; ArgErr: Pointer) : HRESULT
Visibility: default
Description: Invoke must invoke the method designated by DispID. IID can be ignored. LocaleID is
used by the caller to indicate the locale it is using. The Flags argument describes the context in
which Invoke is called: a method, or property getter/setter. The Params argument contains the
parameters to the call. The result should be in VarResult. On error, ExcepInfo and ArgError
should be filled.
The function should return 0 (S_OK) if all went well.
See also: IVCLComObject.GetIDsOfNames (298)
4.33.7 IVCLComObject.SafeCallException
Synopsis: This method can be invoked if an exception occurs during Invoke
Declaration: function SafeCallException(ExceptObject: TObject;
ExceptAddr: CodePointer) : HRESULT
Visibility: default
Description: SafeCallException is called to handle an exception during invocation of the Invoke method.
The TObject implementation of this method returns E_UNEXPECTED.
See also: IVCLComObject.Invoke (298)
4.33.8 IVCLComObject.FreeOnRelease
Synopsis: Is called by TComponent.FreeOnRelease
Declaration: procedure FreeOnRelease
Visibility: default
298
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
Description: FreeOnRelease is called by TComponent.FreeOnRelease (353) for the IVCLComObject in-
terface implemented by TComponent.
See also: TComponent.FreeOnRelease (353)
4.34 TAbstractObjectReader
4.34.1 Description
The Free Pascal streaming mechanism, while compatible with Delphi’s mechanism, differs from
it in the sense that the streaming mechanism uses a driver class when streaming components. The
TAbstractObjectReader class is the base driver class for reading property values from streams.
It consists entirely of abstract methods, which must be implemented by descendant classes.
Different streaming mechanisms can be implemented by making a descendant from TAbstractObjectReader.
The TBinaryObjectReader (318) class is such a descendant class, which streams data in binary (Del-
phi compatible) format.
All methods described in this class, mustbe implemented by descendant classes.
See also: TBinaryObjectReader (318)
4.34.2 Method overview
Page Method Description
300 BeginComponent Marks the reading of a new component.
301 BeginProperty Marks the reading of a property value.
300 BeginRootComponent Starts the reading of the root component.
299 NextValue Returns the type of the next value in the stream.
301 Read Read raw data from stream
301 ReadBinary Read binary data from the stream.
302 ReadCurrency Read a currency value from the stream.
302 ReadDate Read a date value from the stream.
301 ReadFloat Read a float value from the stream.
303 ReadIdent Read an identifier from the stream.
303 ReadInt16 Read a 16-bit integer from the stream.
304 ReadInt32 Read a 32-bit integer from the stream.
304 ReadInt64 Read a 64-bit integer from the stream.
303 ReadInt8 Read an 8-bit integer from the stream.
304 ReadSet Reads a set from the stream.
305 ReadSignature Read resource signature
302 ReadSingle Read a single (real-type) value from the stream.
305 ReadStr Read a shortstring from the stream
305 ReadString Read a string of type StringType from the stream.
306 ReadUnicodeString Read a unicode string value
300 ReadValue Reads the type of the next value.
306 ReadWideString Read a widestring value from the stream.
306 SkipComponent Skip till the end of the component.
306 SkipValue Skip the current value.
4.34.3 TAbstractObjectReader.NextValue
Synopsis: Returns the type of the next value in the stream.
299
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
Declaration: function NextValue : TValueType; Virtual; Abstract
Visibility: public
Description: This function should return the type of the next value in the stream, but should not read the actual
value, i.e. the stream position should not be altered by this method. This is used to ’peek’ in the
stream what value is next.
See also: TAbstractObjectReader.ReadValue (300)
4.34.4 TAbstractObjectReader.ReadValue
Synopsis: Reads the type of the next value.
Declaration: function ReadValue : TValueType; Virtual; Abstract
Visibility: public
Description: This function returns the type of the next value in the stream and reads it. i.e. after the call to this
method, the stream is positioned to read the value of the type returned by this function.
See also: TAbstractObjectReader.ReadValue (300)
4.34.5 TAbstractObjectReader.BeginRootComponent
Synopsis: Starts the reading of the root component.
Declaration: procedure BeginRootComponent; Virtual; Abstract
Visibility: public
Description: This function can be used to initialize the driver class for reading a component. It is called once at
the beginning of the read process, and is immediately followed by a call to BeginComponent (300).
See also: TAbstractObjectReader.BeginComponent (300)
4.34.6 TAbstractObjectReader.BeginComponent
Synopsis: Marks the reading of a new component.
Declaration: procedure BeginComponent(var Flags: TFilerFlags;
var AChildPos: Integer;
var CompClassName: string; var CompName: string)
; Virtual; Abstract
Visibility: public
Description: This method is called when the streaming process wants to start reading a new component.
Descendant classes should override this method to read the start of a component new component
definition and return the needed arguments. Flags should be filled with any flags that were found
at the component definition, as well as AChildPos. The CompClassName should be filled with
the class name of the streamed component, and the CompName argument should be filled with the
name of the component.
AChildPos is used to change the ordering in which components appear below their parent compo-
nent when streaming descendant forms.
See also: TAbstractObjectReader.BeginRootComponent (300), TAbstractObjectReader.BeginProperty (301)
300
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.34.7 TAbstractObjectReader.BeginProperty
Synopsis: Marks the reading of a property value.
Declaration: function BeginProperty : string; Virtual; Abstract
Visibility: public
Description: BeginProperty is called by the streaming system when it wants to read a new property. The
return value of the function is the name of the property which can be read from the stream.
See also: TAbstractObjectReader.BeginComponent (300)
4.34.8 TAbstractObjectReader.Read
Synopsis: Read raw data from stream
Declaration: procedure Read(var Buf; Count: LongInt); Virtual; Abstract
Visibility: public
Description: Read is introduced for Delphi compatibility to read raw data from the component stream. This
should not be used in production code as it will totally mess up the streaming.
See also: TBinaryObjectReader.Read (321), TReader.Read (416)
4.34.9 TAbstractObjectReader.ReadBinary
Synopsis: Read binary data from the stream.
Declaration: procedure ReadBinary(const DestData: TMemoryStream); Virtual; Abstract
Visibility: public
Description: ReadBinary is called when binary data should be read from the stream (i.e. after ReadValue (300)
returned a valuetype of vaBinary). The data should be stored in the DestData memory stream
by descendant classes.
See also: TAbstractObjectReader.ReadFloat (301), TAbstractObjectReader.ReadDate (302), TAbstractObjec-
tReader.ReadSingle (302), TAbstractObjectReader.ReadIdent (303), TAbstractObjectReader.ReadInt8
(303), TAbstractObjectReader.ReadInt16 (303), TAbstractObjectReader.ReadInt32 (304), TAbstrac-
tObjectReader.ReadInt64 (304), TabstractObjectReader.ReadSet (304), TabstractObjectReader.ReadStr
(305), TabstractObjectReader.ReadString (305)
4.34.10 TAbstractObjectReader.ReadFloat
Synopsis: Read a float value from the stream.
Declaration: function ReadFloat : Extended; Virtual; Abstract
Visibility: public
Description: ReadFloat is called by the streaming system when it wants to read a float from the stream (i.e.
after ReadValue (300) returned a valuetype of vaExtended). The return value should be the value
of the float.
301
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
See also: TAbstractObjectReader.ReadFloat (301), TAbstractObjectReader.ReadDate (302), TAbstractObjec-
tReader.ReadSingle (302), TAbstractObjectReader.ReadIdent (303), TAbstractObjectReader.ReadInt8
(303), TAbstractObjectReader.ReadInt16 (303), TAbstractObjectReader.ReadInt32 (304), TAbstrac-
tObjectReader.ReadInt64 (304), TabstractObjectReader.ReadSet (304), TabstractObjectReader.ReadStr
(305), TabstractObjectReader.ReadString (305)
4.34.11 TAbstractObjectReader.ReadSingle
Synopsis: Read a single (real-type) value from the stream.
Declaration: function ReadSingle : Single; Virtual; Abstract
Visibility: public
Description: ReadSingle is called by the streaming system when it wants to read a single-type float from the
stream (i.e. after ReadValue (300) returned a valuetype of vaSingle). The return value should be
the value of the float.
See also: TAbstractObjectReader.ReadFloat (301), TAbstractObjectReader.ReadDate (302), TAbstractObjec-
tReader.ReadSingle (302), TAbstractObjectReader.ReadIdent (303), TAbstractObjectReader.ReadInt8
(303), TAbstractObjectReader.ReadInt16 (303), TAbstractObjectReader.ReadInt32 (304), TAbstrac-
tObjectReader.ReadInt64 (304), TabstractObjectReader.ReadSet (304), TabstractObjectReader.ReadStr
(305), TabstractObjectReader.ReadString (305)
4.34.12 TAbstractObjectReader.ReadDate
Synopsis: Read a date value from the stream.
Declaration: function ReadDate : TDateTime; Virtual; Abstract
Visibility: public
Description: ReadDate is called by the streaming system when it wants to read a date/time value from the
stream (i.e. after ReadValue (300) returned a valuetype of vaDate). The return value should be the
date/time value. (This value can be stored as a float, since TDateTime is nothing but a float.)
See also: TAbstractObjectReader.ReadFloat (301), TAbstractObjectReader.ReadSingle (302), TAbstractOb-
jectReader.ReadIdent (303), TAbstractObjectReader.ReadInt8 (303), TAbstractObjectReader.ReadInt16
(303), TAbstractObjectReader.ReadInt32 (304), TAbstractObjectReader.ReadInt64 (304), Tabstrac-
tObjectReader.ReadSet (304), TabstractObjectReader.ReadStr (305), TabstractObjectReader.ReadString
(305)
4.34.13 TAbstractObjectReader.ReadCurrency
Synopsis: Read a currency value from the stream.
Declaration: function ReadCurrency : Currency; Virtual; Abstract
Visibility: public
Description: ReadCurrency is called when a currency-typed value should be read from the stream. This
abstract method should be overidden by descendant classes, and should return the currency value
read from the stream.
See also: TAbstractObjectWriter.WriteCurrency (310)
302
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.34.14 TAbstractObjectReader.ReadIdent
Synopsis: Read an identifier from the stream.
Declaration: function ReadIdent(ValueType: TValueType) : string; Virtual; Abstract
Visibility: public
Description: ReadIdent is called by the streaming system if it expects to read an identifier of type ValueType
from the stream after a call to ReadValue (300) returned vaIdent. The identifier should be returned
as a string. Note that in some cases the identifier does not actually have to be in the stream. The
following table indicates which identifiers must actually be read:
Table 4.21:
ValueType Expected value
vaIdent Read from stream.
vaNil ’Nil’. This does not have to be read from the stream.
vaFalse ’False’. This does not have to be read from the stream.
vaTrue ’True’. This does not have to be read from the stream.
vaNull ’Null’. This does not have to be read from the stream.
See also: TAbstractObjectReader.ReadFloat (301), TAbstractObjectReader.ReadDate (302), TAbstractObjec-
tReader.ReadSingle (302), TAbstractObjectReader.ReadInt8 (303), TAbstractObjectReader.ReadInt16
(303), TAbstractObjectReader.ReadInt32 (304), TAbstractObjectReader.ReadInt64 (304), Tabstrac-
tObjectReader.ReadSet (304), TabstractObjectReader.ReadStr (305), TabstractObjectReader.ReadString
(305)
4.34.15 TAbstractObjectReader.ReadInt8
Synopsis: Read an 8-bit integer from the stream.
Declaration: function ReadInt8 : ShortInt; Virtual; Abstract
Visibility: public
Description: ReadInt8 is called by the streaming process if it expects to read an integer value with a size of
8 bits (1 byte) from the stream (i.e. after ReadValue (300) returned a valuetype of vaInt8). The
return value is the value if the integer. Note that the size of the value in the stream does not actually
have to be 1 byte.
See also: TAbstractObjectReader.ReadFloat (301), TAbstractObjectReader.ReadDate (302), TAbstractObjec-
tReader.ReadSingle (302), TAbstractObjectReader.ReadIdent (303), TAbstractObjectReader.ReadInt16
(303), TAbstractObjectReader.ReadInt32 (304), TAbstractObjectReader.ReadInt64 (304), Tabstrac-
tObjectReader.ReadSet (304), TabstractObjectReader.ReadStr (305), TabstractObjectReader.ReadString
(305)
4.34.16 TAbstractObjectReader.ReadInt16
Synopsis: Read a 16-bit integer from the stream.
Declaration: function ReadInt16 : SmallInt; Virtual; Abstract
Visibility: public
303
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
Description: ReadInt16 is called by the streaming process if it expects to read an integer value with a size of
16 bits (2 bytes) from the stream (i.e. after ReadValue (300) returned a valuetype of vaInt16). The
return value is the value if the integer. Note that the size of the value in the stream does not actually
have to be 2 bytes.
See also: TAbstractObjectReader.ReadFloat (301), TAbstractObjectReader.ReadDate (302), TAbstractObjec-
tReader.ReadSingle (302), TAbstractObjectReader.ReadIdent (303), TAbstractObjectReader.ReadInt8
(303), TAbstractObjectReader.ReadInt32 (304), TAbstractObjectReader.ReadInt64 (304), Tabstrac-
tObjectReader.ReadSet (304), TabstractObjectReader.ReadStr (305), TabstractObjectReader.ReadString
(305)
4.34.17 TAbstractObjectReader.ReadInt32
Synopsis: Read a 32-bit integer from the stream.
Declaration: function ReadInt32 : LongInt; Virtual; Abstract
Visibility: public
Description: ReadInt32 is called by the streaming process if it expects to read an integer value with a size of
32 bits (4 bytes) from the stream (i.e. after ReadValue (300) returned a valuetype of vaInt32). The
return value is the value of the integer. Note that the size of the value in the stream does not actually
have to be 4 bytes.
See also: TAbstractObjectReader.ReadFloat (301), TAbstractObjectReader.ReadDate (302), TAbstractObjec-
tReader.ReadSingle (302), TAbstractObjectReader.ReadIdent (303), TAbstractObjectReader.ReadInt8
(303), TAbstractObjectReader.ReadInt16 (303), TAbstractObjectReader.ReadInt64 (304), Tabstrac-
tObjectReader.ReadSet (304), TabstractObjectReader.ReadStr (305), TabstractObjectReader.ReadString
(305)
4.34.18 TAbstractObjectReader.ReadInt64
Synopsis: Read a 64-bit integer from the stream.
Declaration: function ReadInt64 : Int64; Virtual; Abstract
Visibility: public
Description: ReadInt64 is called by the streaming process if it expects to read an int64 value with a size of 64
bits (8 bytes) from the stream (i.e. after ReadValue (300) returned a valuetype of vaInt64). The
return value is the value if the integer. Note that the size of the value in the stream does not actually
have to be 8 bytes.
See also: TAbstractObjectReader.ReadFloat (301), TAbstractObjectReader.ReadDate (302), TAbstractObjec-
tReader.ReadSingle (302), TAbstractObjectReader.ReadIdent (303), TAbstractObjectReader.ReadInt8
(303), TAbstractObjectReader.ReadInt16 (303), TAbstractObjectReader.ReadInt32 (304), Tabstrac-
tObjectReader.ReadSet (304), TabstractObjectReader.ReadStr (305), TabstractObjectReader.ReadString
(305)
4.34.19 TAbstractObjectReader.ReadSet
Synopsis: Reads a set from the stream.
Declaration: function ReadSet(EnumType: Pointer) : Integer; Virtual; Abstract
Visibility: public
304
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
Description: This method is called by the streaming system if it expects to read a set from the stream (i.e. after
ReadValue (300) returned a valuetype of vaSet). The return value is the contents of the set, encoded
in a bitmask the following way:
For each (enumerated) value in the set, the bit corresponding to the ordinal value of the enumerated
value should be set. i.e. as 1 shl ord(value).
See also: TAbstractObjectReader.ReadFloat (301), TAbstractObjectReader.ReadDate (302), TAbstractObjec-
tReader.ReadSingle (302), TAbstractObjectReader.ReadIdent (303), TAbstractObjectReader.ReadInt8
(303), TAbstractObjectReader.ReadInt16 (303), TAbstractObjectReader.ReadInt32 (304), TAbstrac-
tObjectReader.ReadInt64 (304), TabstractObjectReader.ReadStr (305), TabstractObjectReader.ReadString
(305)
4.34.20 TAbstractObjectReader.ReadSignature
Synopsis: Read resource signature
Declaration: procedure ReadSignature; Virtual; Abstract
Visibility: public
Description: ReadSignature reads the streaming signature from a stream. This method does nothing. It must
be implemented by descendents that have a signature header in the stream. (such as binary streams)
See also: TAbstractObjectWriter.WriteSignature (308), TBinaryObjectReader.ReadSignature (323)
4.34.21 TAbstractObjectReader.ReadStr
Synopsis: Read a shortstring from the stream
Declaration: function ReadStr : string; Virtual; Abstract
Visibility: public
Description: ReadStr is called by the streaming system if it expects to read a string from the stream (i.e. after
ReadValue (300) returned a valuetype of vaLString,vaWstring or vaString). The return
value is the string.
See also: TAbstractObjectReader.ReadFloat (301), TAbstractObjectReader.ReadDate (302), TAbstractObjec-
tReader.ReadSingle (302), TAbstractObjectReader.ReadIdent (303), TAbstractObjectReader.ReadInt8
(303), TAbstractObjectReader.ReadInt16 (303), TAbstractObjectReader.ReadInt32 (304), TAbstrac-
tObjectReader.ReadInt64 (304), TabstractObjectReader.ReadSet (304), TabstractObjectReader.ReadString
(305)
4.34.22 TAbstractObjectReader.ReadString
Synopsis: Read a string of type StringType from the stream.
Declaration: function ReadString(StringType: TValueType) : string; Virtual
; Abstract
Visibility: public
Description: ReadStr is called by the streaming system if it expects to read a string from the stream (i.e. after
ReadValue (300) returned a valuetype of vaLString,vaWstring or vaString). The return
value is the string.
305
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
See also: TAbstractObjectReader.ReadFloat (301), TAbstractObjectReader.ReadDate (302), TAbstractObjec-
tReader.ReadSingle (302), TAbstractObjectReader.ReadIdent (303), TAbstractObjectReader.ReadInt8
(303), TAbstractObjectReader.ReadInt16 (303), TAbstractObjectReader.ReadInt32 (304), TAbstrac-
tObjectReader.ReadInt64 (304), TabstractObjectReader.ReadSet (304), TabstractObjectReader.ReadStr
(305)
4.34.23 TAbstractObjectReader.ReadWideString
Synopsis: Read a widestring value from the stream.
Declaration: function ReadWideString : WideString; Virtual; Abstract
Visibility: public
Description: ReadWideString is called when a widestring-typed value should be read from the stream. This
abstract method should be overidden by descendant classes.
See also: TAbstractObjectWriter.WriteWideString (311)
4.34.24 TAbstractObjectReader.ReadUnicodeString
Synopsis: Read a unicode string value
Declaration: function ReadUnicodeString : UnicodeString; Virtual; Abstract
Visibility: public
Description: ReadUnicodeString should read a UnicodeString value from the stream. (indicated by the
vaUString value type).
Descendant classes should override this method to actually read a UnicodeString value.
See also: TBinaryObjectWriter.WriteUnicodeString (330), TAbstractObjectReader.ReadWideString (306)
4.34.25 TAbstractObjectReader.SkipComponent
Synopsis: Skip till the end of the component.
Declaration: procedure SkipComponent(SkipComponentInfos: Boolean); Virtual
; Abstract
Visibility: public
Description: This method is used to skip the entire declaration of a component in the stream. Each descendant of
TAbstractObjectReader should implement this in a way which is optimal for the implemented
stream format.
See also: TAbstractObjectReader.BeginComponent (300), TAbstractObjectReader.SkipValue (306)
4.34.26 TAbstractObjectReader.SkipValue
Synopsis: Skip the current value.
Declaration: procedure SkipValue; Virtual; Abstract
Visibility: public
306
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
Description: SkipValue should be used when skipping a value in the stream; The method should determine the
type of the value which should be skipped by itself, if this is necessary.
See also: TAbstractObjectReader.SkipComponent (306)
4.35 TAbstractObjectWriter
4.35.1 Description
Abstract driver class for writing component data.
4.35.2 Method overview
Page Method Description
307 BeginCollection Start writing a collection.
307 BeginComponent Start writing a component
308 BeginList Start writing a list.
308 BeginProperty Start writing a property
308 EndList Mark the end of a list.
308 EndProperty Marks the end of writing of a property.
309 Write Write raw data to stream
309 WriteBinary Writes binary data to the stream.
309 WriteBoolean Writes a boolean value to the stream.
310 WriteCurrency Write a currency value to the stream
310 WriteDate Writes a date type to the stream.
309 WriteFloat Writes a float value to the stream.
310 WriteIdent Writes an identifier to the stream.
310 WriteInteger Writes an integer value to the stream
311 WriteMethodName Writes a methodname to the stream.
311 WriteSet Writes a set value to the stream.
308 WriteSignature Write stream signature to the stream
309 WriteSingle Writes a single-type real value to the stream.
311 WriteString Writes a string value to the stream.
310 WriteUInt64 Write an unsigned 64-bit integer
312 WriteUnicodeString Write a unicode string to the stream.
311 WriteVariant Write a variant to the stream
311 WriteWideString Write a widestring value to the stream
4.35.3 TAbstractObjectWriter.BeginCollection
Synopsis: Start writing a collection.
Declaration: procedure BeginCollection; Virtual; Abstract
Visibility: public
Description: Start writing a collection.
4.35.4 TAbstractObjectWriter.BeginComponent
Synopsis: Start writing a component
307
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
Declaration: procedure BeginComponent(Component: TComponent; Flags: TFilerFlags;
ChildPos: Integer); Virtual; Abstract
Visibility: public
Description: Start writing a component
4.35.5 TAbstractObjectWriter.WriteSignature
Synopsis: Write stream signature to the stream
Declaration: procedure WriteSignature; Virtual; Abstract
Visibility: public
Description: WriteSignature writes the streaming signature to a stream. This method does nothing, it must
be implemented by descendents that have a signature header in the stream. (such as binary streams)
See also: TAbstractObjectReader.ReadSignature (305), TBinaryObjectWriter.WriteSignature (326)
4.35.6 TAbstractObjectWriter.BeginList
Synopsis: Start writing a list.
Declaration: procedure BeginList; Virtual; Abstract
Visibility: public
Description: Start writing a list.
4.35.7 TAbstractObjectWriter.EndList
Synopsis: Mark the end of a list.
Declaration: procedure EndList; Virtual; Abstract
Visibility: public
Description: Mark the end of a list.
4.35.8 TAbstractObjectWriter.BeginProperty
Synopsis: Start writing a property
Declaration: procedure BeginProperty(const PropName: string); Virtual; Abstract
Visibility: public
Description: Start writing a property
4.35.9 TAbstractObjectWriter.EndProperty
Synopsis: Marks the end of writing of a property.
Declaration: procedure EndProperty; Virtual; Abstract
Visibility: public
Description: Marks the end of writing of a property.
308
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.35.10 TAbstractObjectWriter.Write
Synopsis: Write raw data to stream
Declaration: procedure Write(const Buffer; Count: LongInt); Virtual; Abstract
Visibility: public
Description: Write is introduced for Delphi compatibility to write raw data to the component stream. This
should not be used in new production code as it will totally mess up the streaming.
See also: TBinaryObjectWriter.Write (328), TWriter.Write (486)
4.35.11 TAbstractObjectWriter.WriteBinary
Synopsis: Writes binary data to the stream.
Declaration: procedure WriteBinary(const Buffer; Count: LongInt); Virtual; Abstract
Visibility: public
Description: Writes binary data to the stream.
4.35.12 TAbstractObjectWriter.WriteBoolean
Synopsis: Writes a boolean value to the stream.
Declaration: procedure WriteBoolean(Value: Boolean); Virtual; Abstract
Visibility: public
Description: Writes a boolean value to the stream.
4.35.13 TAbstractObjectWriter.WriteFloat
Synopsis: Writes a float value to the stream.
Declaration: procedure WriteFloat(const Value: Extended); Virtual; Abstract
Visibility: public
Description: Writes a float value to the stream.
4.35.14 TAbstractObjectWriter.WriteSingle
Synopsis: Writes a single-type real value to the stream.
Declaration: procedure WriteSingle(const Value: Single); Virtual; Abstract
Visibility: public
Description: Writes a single-type real value to the stream.
309
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.35.15 TAbstractObjectWriter.WriteDate
Synopsis: Writes a date type to the stream.
Declaration: procedure WriteDate(const Value: TDateTime); Virtual; Abstract
Visibility: public
Description: Writes a date type to the stream.
4.35.16 TAbstractObjectWriter.WriteCurrency
Synopsis: Write a currency value to the stream
Declaration: procedure WriteCurrency(const Value: Currency); Virtual; Abstract
Visibility: public
Description: WriteCurrency is called when a currency-typed value should be written to the stream. This
abstract method should be overidden by descendant classes.
See also: TAbstractObjectReader.ReadCurrency (302)
4.35.17 TAbstractObjectWriter.WriteIdent
Synopsis: Writes an identifier to the stream.
Declaration: procedure WriteIdent(const Ident: string); Virtual; Abstract
Visibility: public
Description: Writes an identifier to the stream.
4.35.18 TAbstractObjectWriter.WriteInteger
Synopsis: Writes an integer value to the stream
Declaration: procedure WriteInteger(Value: Int64); Virtual; Abstract
Visibility: public
Description: Writes an integer value to the stream
4.35.19 TAbstractObjectWriter.WriteUInt64
Synopsis: Write an unsigned 64-bit integer
Declaration: procedure WriteUInt64(Value: QWord); Virtual; Abstract
Visibility: public
Description: WriteUInt64 must be overridden by descendant classes to write a 64-bit unsigned Value (val-
uetype vaQWord) to the stream.
Errors: None.
See also: TBinaryObjectWriter.WriteUInt64 (329)
310
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.35.20 TAbstractObjectWriter.WriteVariant
Synopsis: Write a variant to the stream
Declaration: procedure WriteVariant(const Value: Variant); Virtual; Abstract
Visibility: public
Description: WriteVariant must be overridden by descendant classes to write a simple variant type to the
stream. WriteVariant does not write arrays types or complex types.
See also: TBinaryObjectWriter.WriteVariant (330)
4.35.21 TAbstractObjectWriter.WriteMethodName
Synopsis: Writes a methodname to the stream.
Declaration: procedure WriteMethodName(const Name: string); Virtual; Abstract
Visibility: public
Description: Writes a methodname to the stream.
4.35.22 TAbstractObjectWriter.WriteSet
Synopsis: Writes a set value to the stream.
Declaration: procedure WriteSet(Value: LongInt; SetType: Pointer); Virtual
; Abstract
Visibility: public
Description: Writes a set value to the stream.
4.35.23 TAbstractObjectWriter.WriteString
Synopsis: Writes a string value to the stream.
Declaration: procedure WriteString(const Value: string); Virtual; Abstract
Visibility: public
Description: Writes a string value to the stream.
4.35.24 TAbstractObjectWriter.WriteWideString
Synopsis: Write a widestring value to the stream
Declaration: procedure WriteWideString(const Value: WideString); Virtual; Abstract
Visibility: public
Description: WriteCurrency is called when a currency-typed value should be written to the stream. This
abstract method should be overidden by descendant classes.
See also: TAbstractObjectReader.ReadWideString (306)
311
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.35.25 TAbstractObjectWriter.WriteUnicodeString
Synopsis: Write a unicode string to the stream.
Declaration: procedure WriteUnicodeString(const Value: UnicodeString); Virtual
; Abstract
Visibility: public
Description: WriteUnicodeString must be overridden by descendant classes to write a unicodestring (val-
uetype vaUString) value to the stream.
See also: TBinaryObjectWriter.WriteUnicodeString (330)
4.36 TBasicAction
4.36.1 Description
TBasicAction implements a basic action class from which all actions are derived. It introduces all
basic methods of an action, and implements functionality to maintain a list of clients, i.e. components
that are connected with this action.
Do not create instances of TBasicAction. Instead, create a descendant class and create an instance
of this class instead.
See also: TBasicActionLink (316), TComponent (348)
4.36.2 Method overview
Page Method Description
312 Create Creates a new instance of a TBasicAction (312) class.
313 Destroy Destroys the action.
314 Execute Triggers the OnExecute (315) event
314 ExecuteTarget Executes the action on the Target object
313 HandlesTarget Determines whether Target can be handled by this action
314 RegisterChanges Registers a new client with the action.
314 UnRegisterChanges Unregisters a client from the list of clients
315 Update Triggers the OnUpdate (316) event
313 UpdateTarget Notify client controls when the action updates itself.
4.36.3 Property overview
Page Properties Access Description
315 ActionComponent rw Returns the component that initiated the action.
315 OnExecute rw Event triggered when the action executes.
316 OnUpdate rw Event trigged when the application is idle.
4.36.4 TBasicAction.Create
Synopsis: Creates a new instance of a TBasicAction (312) class.
Declaration: constructor Create(AOwner: TComponent); Override
Visibility: public
312
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
Description: Create calls the inherited constructor, and then initializes the list of clients controls (or action
lists).
Under normal circumstances it should not be necessary to create a TBasicAction descendant
manually, actions are created in an IDE.
See also: Destroy (313), AssignClient (312)
4.36.5 TBasicAction.Destroy
Synopsis: Destroys the action.
Declaration: destructor Destroy; Override
Visibility: public
Description: Destroy cleans up the list of client controls and then calls the inherited destructor.
An application programmer should not call Destroy directly; Instead Free should be called, if it
needs to be called at all. Normally the controlling class (e.g. a TActionList) will destroy the action.
4.36.6 TBasicAction.HandlesTarget
Synopsis: Determines whether Target can be handled by this action
Declaration: function HandlesTarget(Target: TObject) : Boolean; Virtual
Visibility: public
Description: HandlesTarget returns True if Target is a valid client for this action and if so, if it is
in a suitable state to execute the action. An application programmer should never need to call
HandlesTarget directly, it will be called by the action itself when needed.
In TBasicAction this method is empty; descendant classes should override this method to imple-
ment appropriate checks.
See also: UpdateTarget (313), ExecuteTarget (314)
4.36.7 TBasicAction.UpdateTarget
Synopsis: Notify client controls when the action updates itself.
Declaration: procedure UpdateTarget(Target: TObject); Virtual
Visibility: public
Description: UpdateTarget should update the client control specified by Target when the action updates
itself. In TBasicAction, the implementation of UpdateTarget is empty. Descendant classes
should override and implement UpdateTarget to actually update the Target object.
An application programmer should never need to call HandlesTarget directly, it will be called
by the action itself when needed.
See also: HandlesTarget (313), ExecuteTarget (314)
313
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.36.8 TBasicAction.ExecuteTarget
Synopsis: Executes the action on the Target object
Declaration: procedure ExecuteTarget(Target: TObject); Virtual
Visibility: public
Description: ExecuteTarget performs the action on the Target object. In TBasicAction this method
does nothing. Descendant classes should implement the action to be performed. For instance an
action to post data in a dataset could call the Post method of the dataset.
An application programmer should never call ExecuteTarget directly.
See also: HandlesTarget (313), UpdateTarget (314), Execute (314)
4.36.9 TBasicAction.Execute
Synopsis: Triggers the OnExecute (315) event
Declaration: function Execute : Boolean; Dynamic
Visibility: public
Description: Execute triggers the OnExecute event, if one is assigned. It returns True if the event handler
was called, False otherwise.
4.36.10 TBasicAction.RegisterChanges
Synopsis: Registers a new client with the action.
Declaration: procedure RegisterChanges(Value: TBasicActionLink)
Visibility: public
Description: RegisterChanges adds Value to the list of clients.
See also: UnregisterChanges (314)
4.36.11 TBasicAction.UnRegisterChanges
Synopsis: Unregisters a client from the list of clients
Declaration: procedure UnRegisterChanges(Value: TBasicActionLink)
Visibility: public
Description: UnregisterChanges removes Value from the list of clients. This is called for instance when
the action is destroyed, or when the client is assigned a new action.
See also: UnregisterChanges (314), Destroy (313)
314
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.36.12 TBasicAction.Update
Synopsis: Triggers the OnUpdate (316) event
Declaration: function Update : Boolean; Virtual
Visibility: public
Description: Update triggers the OnUpdate event, if one is assigned. It returns True if the event was triggered,
or False if no event was assigned.
Application programmers should never run Update directly. The Update method is called auto-
matically by the action mechanism; Normally this is in the Idle time of an application. An application
programmer should assign the OnUpdate (316) event, and perform any checks in that handler.
See also: OnUpdate (316), Execute (314), UpdateTarget (313)
4.36.13 TBasicAction.ActionComponent
Synopsis: Returns the component that initiated the action.
Declaration: Property ActionComponent : TComponent
Visibility: public
Access: Read,Write
Description: ActionComponent is set to the component that caused the action to execute, e.g. a toolbutton or
a menu item. The property is set just before the action executes, and is reset to nil after the action
was executed.
See also: Execute (314), OnExecute (315)
4.36.14 TBasicAction.OnExecute
Synopsis: Event triggered when the action executes.
Declaration: Property OnExecute : TNotifyEvent
Visibility: public
Access: Read,Write
Description: OnExecute is the event triggered when the action is activated (executed). The event is triggered
e.g. when the user clicks e.g. on a menu item or a button associated to the action. The application
programmer should provide a OnExecute event handler to execute whatever code is necessary
when the button is pressed or the menu item is chosen.
Note that assigning an OnExecute handler will result in the Execute (314) method returning a
True value. Predefined actions (such as dataset actions) will check the result of Execute and will
not perform their normal task if the OnExecute handler was called.
See also: Execute (314), OnUpdate (316)
315
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.36.15 TBasicAction.OnUpdate
Synopsis: Event trigged when the application is idle.
Declaration: Property OnUpdate : TNotifyEvent
Visibility: public
Access: Read,Write
Description: OnUpdate is the event triggered when the application is idle, and the action is being updated. The
OnUpdate event can be used to set the state of the action, for instance disable it if the action cannot
be executed at this point in time.
See also: Update (315), OnExecute (315)
4.37 TBasicActionLink
4.37.1 Description
TBasicActionLink links an Action to its clients. With each client for an action, a TBasicActionLink
class is instantiated to handle the communication between the action and the client. It passes events
between the action and its clients, and thus presents the action with a uniform interface to the clients.
An application programmer should never use a TBasicActionLink instance directly; They are
created automatically when an action is associated with a component. Component programmers
should create specialized descendants of TBasicActionLink which communicate changes in the
action to the component.
See also: TBasicAction (312)
4.37.2 Method overview
Page Method Description
316 Create Creates a new instance of the TBasicActionLink class
317 Destroy Destroys the TBasicActionLink instance.
317 Execute Calls the action’s Execute method.
317 Update Calls the action’s Update method
4.37.3 Property overview
Page Properties Access Description
318 Action rw The action to which the link was assigned.
318 OnChange rw Event handler triggered when the action’s properties change
4.37.4 TBasicActionLink.Create
Synopsis: Creates a new instance of the TBasicActionLink class
Declaration: constructor Create(AClient: TObject); Virtual
Visibility: public
316
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
Description: Create creates a new instance of a TBasicActionLink and assigns AClient as the client of
the link.
Application programmers should never instantiate TBasicActionLink classes directly. An in-
stance is created automatically when an action is assigned to a control (client).
Component programmers can override the create constructor to initialize further properties.
See also: Destroy (317)
4.37.5 TBasicActionLink.Destroy
Synopsis: Destroys the TBasicActionLink instance.
Declaration: destructor Destroy; Override
Visibility: public
Description: Destroy unregisters the TBasicActionLink with the action, and then calls the inherited de-
structor.
Application programmers should never call Destroy directly. If a link should be destroyed at all,
the Free method should be called instead.
See also: Create (316)
4.37.6 TBasicActionLink.Execute
Synopsis: Calls the action’s Execute method.
Declaration: function Execute(AComponent: TComponent) : Boolean; Virtual
Visibility: public
Description: Execute sets the ActionComponent (315) property of the associated Action (318) to AComponent
and then calls the Action’s execute (314) method. After the action has executed, the ActionComponent
property is cleared again.
The return value of the function is the return value of the Action’s execute method.
Application programmers should never call Execute directly. This method will be called automat-
ically when the associated control is activated. (e.g. a button is clicked on)
Component programmers should call Execute whenever the action should be activated.
See also: Action (318), TBasicAction.ActionComponent (315), TBasicAction.Execute (314), TBasicAction.onExecute
(315)
4.37.7 TBasicActionLink.Update
Synopsis: Calls the action’s Update method
Declaration: function Update : Boolean; Virtual
Visibility: public
Description: Update calls the associated Action’s Update (315) methoda.
Component programmers can override the Update method to provide additional processing when
the Update method occurs.
317
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.37.8 TBasicActionLink.Action
Synopsis: The action to which the link was assigned.
Declaration: Property Action : TBasicAction
Visibility: public
Access: Read,Write
Description: Action represents the Action (312) which was assigned to the client. Setting this property will
unregister the client at the old action (if one existed) and registers the client at the new action.
See also: TBasicAction (312)
4.37.9 TBasicActionLink.OnChange
Synopsis: Event handler triggered when the action’s properties change
Declaration: Property OnChange : TNotifyEvent
Visibility: public
Access: Read,Write
Description: OnChange is the event triggered when the action’s properties change.
Application programmers should never need to assign this event. Component programmers can
assign this event to have a client control reflect any changes in an Action’s properties.
See also: Change (316), TBasicAction.Change (312)
4.38 TBinaryObjectReader
4.38.1 Description
The TBinaryObjectReader class reads component data stored in binary form in a file. For
this, it overrides or implements all abstract methods from TAbstractObjectReader (299). No new
functionality is added by this class, it is a driver class for the streaming system.
It should never be necessary to create an instance of this class directly. Instead, the TStream.WriteComponent
(432) call should be used.
See also: TAbstractObjectReader (299), TBinaryObjectWriter (325)
318
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.38.2 Method overview
Page Method Description
320 BeginComponent Start reading a component.
321 BeginProperty Start reading a property.
320 BeginRootComponent Start reading the root component.
319 Create Creates a new binary data reader instance.
319 Destroy Destroys the binary data reader.
320 NextValue Return the type of the next value.
321 Read Read raw data from stream
321 ReadBinary Start reading a binary value.
322 ReadCurrency Read a currency value from the stream.
322 ReadDate Read a date.
321 ReadFloat Read a float value
322 ReadIdent Read an identifier
322 ReadInt16 Read a 16-bits integer.
323 ReadInt32 Read a 32-bits integer.
323 ReadInt64 Read a 64-bits integer.
322 ReadInt8 Read an 8-bits integer.
323 ReadSet Read a set
323 ReadSignature Reads the filer signature
321 ReadSingle Read a single-size float value
324 ReadStr Read a short string
324 ReadString Read a string
324 ReadUnicodeString Read a unicode string value
320 ReadValue Read the next value in the stream
324 ReadWideString Read a widestring value from the stream.
325 SkipComponent Skip a component’s data
325 SkipValue Skip a value’s data
4.38.3 TBinaryObjectReader.Create
Synopsis: Creates a new binary data reader instance.
Declaration: constructor Create(Stream: TStream; BufSize: Integer)
Visibility: public
Description: Create instantiates a new binary component data reader. The Stream stream is the stream from
which data will be read. The BufSize argument is the size of the internal buffer that will be used
by the reader. This can be used to optimize the reading process.
See also: TAbstractObjectReader (299)
4.38.4 TBinaryObjectReader.Destroy
Synopsis: Destroys the binary data reader.
Declaration: destructor Destroy; Override
Visibility: public
Description: Destroy frees the buffer allocated when the instance was created. It also positions the stream on
the last used position in the stream (the buffering may cause the reader to read more bytes than were
actually used.)
See also: TBinaryObjectReader.Create (319)
319
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.38.5 TBinaryObjectReader.NextValue
Synopsis: Return the type of the next value.
Declaration: function NextValue : TValueType; Override
Visibility: public
Description: NextValue returns the type of the next value in a binary stream, but does not read the value.
This method is simply the implementation for a binary stream of the abstract method introduced in
TAbstractObjectReader (299)
4.38.6 TBinaryObjectReader.ReadValue
Synopsis: Read the next value in the stream
Declaration: function ReadValue : TValueType; Override
Visibility: public
Description: NextValue reads the next value in a binary stream and returns the type of the read value.
This method is simply the implementation for a binary stream of the abstract method introduced in
TAbstractObjectReader (299)
4.38.7 TBinaryObjectReader.BeginRootComponent
Synopsis: Start reading the root component.
Declaration: procedure BeginRootComponent; Override
Visibility: public
Description: BeginRootComponent starts reading the root component in a binary stream.
This method is simply the implementation for a binary stream of the abstract method introduced in
TAbstractObjectReader (299)
4.38.8 TBinaryObjectReader.BeginComponent
Synopsis: Start reading a component.
Declaration: procedure BeginComponent(var Flags: TFilerFlags;
var AChildPos: Integer;
var CompClassName: string; var CompName: string)
; Override
Visibility: public
Description: This method is simply the implementation for a binary stream of the abstract method introduced in
TAbstractObjectReader (299)
320
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.38.9 TBinaryObjectReader.BeginProperty
Synopsis: Start reading a property.
Declaration: function BeginProperty : string; Override
Visibility: public
Description: This method is simply the implementation for a binary stream of the abstract method introduced in
TAbstractObjectReader (299)
4.38.10 TBinaryObjectReader.Read
Synopsis: Read raw data from stream
Declaration: procedure Read(var Buf; Count: LongInt); Override
Visibility: public
Description: Read is introduced for Delphi compatibility to read raw data from the component stream. This
should not be used in production code as it will totally mess up the streaming.
See also: TAbstractObjectReader.Read (301), TReader.Read (416)
4.38.11 TBinaryObjectReader.ReadBinary
Synopsis: Start reading a binary value.
Declaration: procedure ReadBinary(const DestData: TMemoryStream); Override
Visibility: public
Description: ReadBinary reads a binary valye from a binary stream.
This method is simply the implementation for a binary stream of the abstract method introduced in
TAbstractObjectReader (299)
4.38.12 TBinaryObjectReader.ReadFloat
Synopsis: Read a float value
Declaration: function ReadFloat : Extended; Override
Visibility: public
Description: ReadFloat reads a float value from a binary stream.
This method is simply the implementation for a binary stream of the abstract method introduced in
TAbstractObjectReader (299)
4.38.13 TBinaryObjectReader.ReadSingle
Synopsis: Read a single-size float value
Declaration: function ReadSingle : Single; Override
Visibility: public
Description: ReadSingle reads a single-sized float value from a binary stream.
This method is simply the implementation for a binary stream of the abstract method introduced in
TAbstractObjectReader (299)
321
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.38.14 TBinaryObjectReader.ReadDate
Synopsis: Read a date.
Declaration: function ReadDate : TDateTime; Override
Visibility: public
Description: ReadDate reads a date value from a binary stream.
This method is simply the implementation for a binary stream of the abstract method introduced in
TAbstractObjectReader (299)
4.38.15 TBinaryObjectReader.ReadCurrency
Synopsis: Read a currency value from the stream.
Declaration: function ReadCurrency : Currency; Override
Visibility: public
Description: var>ReadCurrency reads a currency-typed value from a binary stream. It is the implementation
of the method introduced in TAbstractObjectReader (299).
See also: TAbstractObjectReader.ReadCurrency (302), TBinaryObjectWriter.WriteCurrency (329)
4.38.16 TBinaryObjectReader.ReadIdent
Synopsis: Read an identifier
Declaration: function ReadIdent(ValueType: TValueType) : string; Override
Visibility: public
Description: ReadIdent reads an identifier from a binary stream.
This method is simply the implementation for a binary stream of the abstract method introduced in
TAbstractObjectReader (299)
4.38.17 TBinaryObjectReader.ReadInt8
Synopsis: Read an 8-bits integer.
Declaration: function ReadInt8 : ShortInt; Override
Visibility: public
Description: Read8Int reads an 8-bits signed integer from a binary stream.
This method is simply the implementation for a binary stream of the abstract method introduced in
TAbstractObjectReader (299)
4.38.18 TBinaryObjectReader.ReadInt16
Synopsis: Read a 16-bits integer.
Declaration: function ReadInt16 : SmallInt; Override
Visibility: public
322
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
Description: Read16Int reads a 16-bits signed integer from a binary stream.
This method is simply the implementation for a binary stream of the abstract method introduced in
TAbstractObjectReader (299)
4.38.19 TBinaryObjectReader.ReadInt32
Synopsis: Read a 32-bits integer.
Declaration: function ReadInt32 : LongInt; Override
Visibility: public
Description: Read32Int reads a 32-bits signed integer from a binary stream.
This method is simply the implementation for a binary stream of the abstract method introduced in
TAbstractObjectReader (299)
4.38.20 TBinaryObjectReader.ReadInt64
Synopsis: Read a 64-bits integer.
Declaration: function ReadInt64 : Int64; Override
Visibility: public
Description: Read64Int reads a 64-bits signed integer from a binary stream.
This method is simply the implementation for a binary stream of the abstract method introduced in
TAbstractObjectReader (299)
4.38.21 TBinaryObjectReader.ReadSet
Synopsis: Read a set
Declaration: function ReadSet(EnumType: Pointer) : Integer; Override
Visibility: public
Description: ReadSet reads a set from a binary stream.
This method is simply the implementation for a binary stream of the abstract method introduced in
TAbstractObjectReader (299)
4.38.22 TBinaryObjectReader.ReadSignature
Synopsis: Reads the filer signature
Declaration: procedure ReadSignature; Override
Visibility: public
Description: ReadSignature is overridden by TBinaryObjectReader to read the signature (TPF0) from
binary streams.
Errors: If the stream does not start with the correct signature, an EReadError (285) exception is raised.
See also: TAbstractObjectReader.ReadSignature (305), TAbstractObjectWriter.WriteSignature (308), TBina-
ryObjectWriter.WriteSignature (326)
323
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.38.23 TBinaryObjectReader.ReadStr
Synopsis: Read a short string
Declaration: function ReadStr : string; Override
Visibility: public
Description: ReadStr reads a short string from a binary stream.
This method is simply the implementation for a binary stream of the abstract method introduced in
TAbstractObjectReader (299)
4.38.24 TBinaryObjectReader.ReadString
Synopsis: Read a string
Declaration: function ReadString(StringType: TValueType) : string; Override
Visibility: public
Description: ReadStr reads a string of type StringType from a binary stream.
This method is simply the implementation for a binary stream of the abstract method introduced in
TAbstractObjectReader (299)
4.38.25 TBinaryObjectReader.ReadWideString
Synopsis: Read a widestring value from the stream.
Declaration: function ReadWideString : WideString; Override
Visibility: public
Description: var>ReadWideString reads a widestring-typed value from a binary stream. It is the implemen-
tation of the method introduced in TAbstractObjectReader (299).
See also: TAbstractObjectReader.ReadWideString (306), TBinaryObjectWriter.WriteWideString (330)
4.38.26 TBinaryObjectReader.ReadUnicodeString
Synopsis: Read a unicode string value
Declaration: function ReadUnicodeString : UnicodeString; Override
Visibility: public
Description: ReadUnicodeString is overridden by TBinaryObjectReaderto read a UnicodeString value
from the binary stream.
See also: TAbstractObjectReader.ReadUnicodeString (306)
324
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.38.27 TBinaryObjectReader.SkipComponent
Synopsis: Skip a component’s data
Declaration: procedure SkipComponent(SkipComponentInfos: Boolean); Override
Visibility: public
Description: SkipComponent skips the data of a component in a binary stream.
This method is simply the implementation for a binary stream of the abstract method introduced in
TAbstractObjectReader (299).
4.38.28 TBinaryObjectReader.SkipValue
Synopsis: Skip a value’s data
Declaration: procedure SkipValue; Override
Visibility: public
Description: SkipComponent skips the data of the next value in a binary stream.
This method is simply the implementation for a binary stream of the abstract method introduced in
TAbstractObjectReader (299)
4.39 TBinaryObjectWriter
4.39.1 Description
Driver class which stores component data in binary form.
325
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.39.2 Method overview
Page Method Description
327 BeginCollection Start writing a collection.
327 BeginComponent Start writing a component
327 BeginList Start writing a list.
327 BeginProperty Start writing a property
326 Create Creates a new instance of a binary object writer.
326 Destroy Destroys an instance of the binary object writer.
327 EndList Mark the end of a list.
327 EndProperty Marks the end of writing of a property.
328 Write Write raw data to stream
328 WriteBinary Writes binary data to the stream.
328 WriteBoolean Writes a boolean value to the stream.
329 WriteCurrency Write a currency-valued type to a stream
328 WriteDate Writes a date type to the stream.
328 WriteFloat Writes a float value to the stream.
329 WriteIdent Writes an identifier to the stream.
329 WriteInteger Writes an integer value to the stream.
329 WriteMethodName Writes a methodname to the stream.
329 WriteSet Writes a set value to the stream.
326 WriteSignature Write stream signature to the stream
328 WriteSingle Writes a single-type real value to the stream.
330 WriteStr Write a string to the binary stream
330 WriteString Writes a string value to the stream.
329 WriteUInt64 Write an unsigned 64-bit integer
330 WriteUnicodeString Write a unicode string to the stream.
330 WriteVariant Write a variant to the stream
330 WriteWideString Write a widestring-valued type to a stream
4.39.3 TBinaryObjectWriter.Create
Synopsis: Creates a new instance of a binary object writer.
Declaration: constructor Create(Stream: TStream; BufSize: Integer)
Visibility: public
Description: Creates a new instance of a binary object writer.
4.39.4 TBinaryObjectWriter.Destroy
Synopsis: Destroys an instance of the binary object writer.
Declaration: destructor Destroy; Override
Visibility: public
Description: Destroys an instance of the binary object writer.
4.39.5 TBinaryObjectWriter.WriteSignature
Synopsis: Write stream signature to the stream
Declaration: procedure WriteSignature; Override
326
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
Visibility: public
Description: WriteSignature is overridden by TBinaryObjectWriter to write the signature (TPF0) to
binary streams.
See also: TAbstractObjectWriter.WriteSignature (308), TAbstractObjectReader.ReadSignature (305), TBina-
ryObjectReader.ReadSignature (323)
4.39.6 TBinaryObjectWriter.BeginCollection
Synopsis: Start writing a collection.
Declaration: procedure BeginCollection; Override
Visibility: public
4.39.7 TBinaryObjectWriter.BeginComponent
Synopsis: Start writing a component
Declaration: procedure BeginComponent(Component: TComponent; Flags: TFilerFlags;
ChildPos: Integer); Override
Visibility: public
4.39.8 TBinaryObjectWriter.BeginList
Synopsis: Start writing a list.
Declaration: procedure BeginList; Override
Visibility: public
4.39.9 TBinaryObjectWriter.EndList
Synopsis: Mark the end of a list.
Declaration: procedure EndList; Override
Visibility: public
4.39.10 TBinaryObjectWriter.BeginProperty
Synopsis: Start writing a property
Declaration: procedure BeginProperty(const PropName: string); Override
Visibility: public
4.39.11 TBinaryObjectWriter.EndProperty
Synopsis: Marks the end of writing of a property.
Declaration: procedure EndProperty; Override
Visibility: public
327
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.39.12 TBinaryObjectWriter.Write
Synopsis: Write raw data to stream
Declaration: procedure Write(const Buffer; Count: LongInt); Override
Visibility: public
Description: Write is introduced for Delphi compatibility to write raw data to the component stream. This
should not be used in new production code as it will totally mess up the streaming.
See also: TAbstractObjectWriter.Write (309), TWriter.Write (486)
4.39.13 TBinaryObjectWriter.WriteBinary
Synopsis: Writes binary data to the stream.
Declaration: procedure WriteBinary(const Buffer; Count: LongInt); Override
Visibility: public
4.39.14 TBinaryObjectWriter.WriteBoolean
Synopsis: Writes a boolean value to the stream.
Declaration: procedure WriteBoolean(Value: Boolean); Override
Visibility: public
4.39.15 TBinaryObjectWriter.WriteFloat
Synopsis: Writes a float value to the stream.
Declaration: procedure WriteFloat(const Value: Extended); Override
Visibility: public
4.39.16 TBinaryObjectWriter.WriteSingle
Synopsis: Writes a single-type real value to the stream.
Declaration: procedure WriteSingle(const Value: Single); Override
Visibility: public
4.39.17 TBinaryObjectWriter.WriteDate
Synopsis: Writes a date type to the stream.
Declaration: procedure WriteDate(const Value: TDateTime); Override
Visibility: public
328
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.39.18 TBinaryObjectWriter.WriteCurrency
Synopsis: Write a currency-valued type to a stream
Declaration: procedure WriteCurrency(const Value: Currency); Override
Visibility: public
Description: WriteCurrency writes a currency-typed value to a binary stream. It is the implementation of the
method introduced in TAbstractObjectWriter (307).
See also: TAbstractObjectWriter.WriteCurrency (310)
4.39.19 TBinaryObjectWriter.WriteIdent
Synopsis: Writes an identifier to the stream.
Declaration: procedure WriteIdent(const Ident: string); Override
Visibility: public
4.39.20 TBinaryObjectWriter.WriteInteger
Synopsis: Writes an integer value to the stream.
Declaration: procedure WriteInteger(Value: Int64); Override
Visibility: public
4.39.21 TBinaryObjectWriter.WriteUInt64
Synopsis: Write an unsigned 64-bit integer
Declaration: procedure WriteUInt64(Value: QWord); Override
Visibility: public
Description: WriteUInt64 is overridden by TBinaryObjectWriter to write an unsigned 64-bit integer
(QWord) to the stream. It tries to use the smallest possible storage for the value that is passed.
(largest valuetype will be vaQWord).
See also: TAbstractObjectWriter.WriteUInt64 (310)
4.39.22 TBinaryObjectWriter.WriteMethodName
Synopsis: Writes a methodname to the stream.
Declaration: procedure WriteMethodName(const Name: string); Override
Visibility: public
4.39.23 TBinaryObjectWriter.WriteSet
Synopsis: Writes a set value to the stream.
Declaration: procedure WriteSet(Value: LongInt; SetType: Pointer); Override
Visibility: public
329
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.39.24 TBinaryObjectWriter.WriteStr
Synopsis: Write a string to the binary stream
Declaration: procedure WriteStr(const Value: string)
Visibility: public
Description: WriteStr writes a string value to the binary stream. It is exposed so it can be used in DefineProperties.
4.39.25 TBinaryObjectWriter.WriteString
Synopsis: Writes a string value to the stream.
Declaration: procedure WriteString(const Value: string); Override
Visibility: public
4.39.26 TBinaryObjectWriter.WriteWideString
Synopsis: Write a widestring-valued type to a stream
Declaration: procedure WriteWideString(const Value: WideString); Override
Visibility: public
Description: WriteWidestring writes a widestring-typed value to a binary stream. It is the implementation
of the method introduced in TAbstractObjectWriter (307).
See also: TAbstractObjectWriter.WriteWidestring (311)
4.39.27 TBinaryObjectWriter.WriteUnicodeString
Synopsis: Write a unicode string to the stream.
Declaration: procedure WriteUnicodeString(const Value: UnicodeString); Override
Visibility: public
Description: WriteUnicodeString is overridden TBinaryObjectWriter to write a unicodestring (val-
uetype vaUString) value to the stream. It simply writes the character length and then all widechar-
acters.
See also: TAbstractObjectWriter.WriteUnicodeString (312)
4.39.28 TBinaryObjectWriter.WriteVariant
Synopsis: Write a variant to the stream
Declaration: procedure WriteVariant(const VarValue: Variant); Override
Visibility: public
Description: WriteVariant is overridden by TBinaryObjectWriter to write a simple variant type to the
stream. WriteVariant does not write arrays types or complex types. Only null, integer (ordinal)
float and string types are written.
Errors: If a non-supported type is written, then an EWriteError exception is.
330
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.40 TBits
4.40.1 Description
TBits can be used to store collections of bits in an indexed array. This is especially useful for
storing collections of booleans: Normally the size of a boolean is the size of the smallest enumerated
type, i.e. 1 byte. Since a bit can take 2 values it can be used to store a boolean as well. Since TBits
can store 8 bits in a byte, it takes 8 times less space to store an array of booleans in a TBits class then
it would take to store them in a conventional array.
TBits introduces methods to store and retrieve bit values, apply masks, and search for bits.
4.40.2 Method overview
Page Method Description
333 AndBits Performs an and operation on the bits.
332 Clear Clears a particular bit.
333 Clearall Clears all bits in the array.
331 Create Creates a new bits collection.
332 Destroy Destroys a bit collection
335 Equals Determines whether the bits of 2 arrays are equal.
335 FindFirstBit Find first bit with a particular value
336 FindNextBit Searches the next bit with a particular value.
336 FindPrevBit Searches the previous bit with a particular value.
334 Get Retrieve the value of a particular bit
332 GetFSize Returns the number of records used to store the bits.
334 Grow Expands the bits array to the requested size.
334 NotBits Performs a not operation on the bits.
336 OpenBit Returns the position of the first bit that is set to False.
333 OrBits Performs an or operation on the bits.
335 SetIndex Sets the start position for FindNextBit (336) and FindPrevBit (336)
332 SetOn Turn a particular bit on.
333 XorBits Performs a xor operation on the bits.
4.40.3 Property overview
Page Properties Access Description
337 Bits rw Access to all bits in the array.
337 Size rw Current size of the array of bits.
4.40.4 TBits.Create
Synopsis: Creates a new bits collection.
Declaration: constructor Create(TheSize: LongInt); Virtual
Visibility: public
Description: Create creates a new bit collection with initial size TheSize. The size of the collection can be
changed later on.
All bits are initially set to zero.
See also: Destroy (332)
331
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.40.5 TBits.Destroy
Synopsis: Destroys a bit collection
Declaration: destructor Destroy; Override
Visibility: public
Description: Destroy destroys a previously created bit collection and releases all memory used to store the bit
collection.
Destroy should never be called directly, Free should be used instead.
Errors: None.
See also: Create (331)
4.40.6 TBits.GetFSize
Synopsis: Returns the number of records used to store the bits.
Declaration: function GetFSize : LongInt
Visibility: public
Description: GetFSize returns the number of records used to store the current number of bits.
Errors: None.
See also: Size (337)
4.40.7 TBits.SetOn
Synopsis: Turn a particular bit on.
Declaration: procedure SetOn(Bit: LongInt)
Visibility: public
Description: SetOn turns on the bit at position bit, i.e. sets it to 1. If bit is at a position bigger than the
current size, the collection is expanded to the required size using Grow (334).
Errors: If bit is larger than the maximum allowed bits array size or is negative, an EBitsError (282) excep-
tion is raised.
See also: Bits (337), Clear (332)
4.40.8 TBits.Clear
Synopsis: Clears a particular bit.
Declaration: procedure Clear(Bit: LongInt)
Visibility: public
Description: Clear clears the bit at position bit. If the array If bit is at a position bigger than the current size,
the collection is expanded to the required size using Grow (334).
Errors: If bit is larger than the maximum allowed bits array size or is negative, an EBitsError (282) excep-
tion is raised.
See also: Bits (337), seton (332)
332
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.40.9 TBits.Clearall
Synopsis: Clears all bits in the array.
Declaration: procedure Clearall
Visibility: public
Description: ClearAll clears all bits in the array, i.e. sets them to zero. ClearAll works faster than clearing
all individual bits, since it uses the packed nature of the bits.
Errors: None.
See also: Bits (337), clear (332)
4.40.10 TBits.AndBits
Synopsis: Performs an and operation on the bits.
Declaration: procedure AndBits(BitSet: TBits)
Visibility: public
Description: andbits performs an and operation on the bits in the array with the bits of array BitSet. If
BitSet contains less bits than the current array, then all bits which have no counterpart in BitSet
are cleared.
Errors: None.
See also: ClearAll (333), OrBits (333), XOrBits (333), NotBits (334)
4.40.11 TBits.OrBits
Synopsis: Performs an or operation on the bits.
Declaration: procedure OrBits(BitSet: TBits)
Visibility: public
Description: andbits performs an or operation on the bits in the array with the bits of array BitSet.
If BitSet contains less bits than the current array, then all bits which have no counterpart in
BitSet are left untouched.
If the current array contains less bits than BitSet then it is grown to the size of BitSet before the
or operation is performed.
Errors: None.
See also: ClearAll (333), andBits (333), XOrBits (333), NotBits (334)
4.40.12 TBits.XorBits
Synopsis: Performs a xor operation on the bits.
Declaration: procedure XorBits(BitSet: TBits)
Visibility: public
333
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
Description: XorBits performs a xor operation on the bits in the array with the bits of array BitSet.
If BitSet contains less bits than the current array, then all bits which have no counterpart in
BitSet are left untouched.
If the current array contains less bits than BitSet then it is grown to the size of BitSet before the
xor operation is performed.
Errors: None.
See also: ClearAll (333), andBits (333), OrBits (333), NotBits (334)
4.40.13 TBits.NotBits
Synopsis: Performs a not operation on the bits.
Declaration: procedure NotBits(BitSet: TBits)
Visibility: public
Description: NotBits performs a not operation on the bits in the array with the bits of array Bitset.
If BitSet contains less bits than the current array, then all bits which have no counterpart in
BitSet are left untouched.
Errors: None.
See also: ClearAll (333), andBits (333), OrBits (333), XOrBits (333)
4.40.14 TBits.Get
Synopsis: Retrieve the value of a particular bit
Declaration: function Get(Bit: LongInt) : Boolean
Visibility: public
Description: Get returns True if the bit at position bit is set, or False if it is not set.
Errors: If bit is not a valid bit index then an EBitsError (282) exception is raised.
See also: Bits (337), FindFirstBit (335), seton (332)
4.40.15 TBits.Grow
Synopsis: Expands the bits array to the requested size.
Declaration: procedure Grow(NBit: LongInt)
Visibility: public
Description: Grow expands the bit array so it can at least contain nbit bits. If nbit is less than the current size,
nothing happens.
Errors: If there is not enough memory to complete the operation, then an EBitsError (282)is raised.
See also: Size (337)
334
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.40.16 TBits.Equals
Synopsis: Determines whether the bits of 2 arrays are equal.
Declaration: function Equals(Obj: TObject) : Boolean; Override; Overload
function Equals(BitSet: TBits) : Boolean; Overload
Visibility: public
Description: equals returns True if all the bits in BitSet are the same as the ones in the current BitSet; if
not, False is returned.
If the sizes of the two BitSets are different, the arrays are still reported equal when all the bits in the
larger set, which are not present in the smaller set, are zero.
Errors: None.
See also: ClearAll (333), andBits (333), OrBits (333), XOrBits (333)
4.40.17 TBits.SetIndex
Synopsis: Sets the start position for FindNextBit (336) and FindPrevBit (336)
Declaration: procedure SetIndex(Index: LongInt)
Visibility: public
Description: SetIndex sets the search start position forFindNextBit (336) and FindPrevBit (336) to Index.
This means that these calls will start searching from position Index.
This mechanism provides an alternative to FindFirstBit (335) which can also be used to position for
the FindNextBit and FindPrevBit calls.
Errors: None.
See also: FindNextBit (336), FindPrevBit (336), FindFirstBit (335), OpenBit (336)
4.40.18 TBits.FindFirstBit
Synopsis: Find first bit with a particular value
Declaration: function FindFirstBit(State: Boolean) : LongInt
Visibility: public
Description: FindFirstBit searches for the first bit with value State. It returns the position of this bit, or
-1 if no such bit was found.
The search starts at position 0 in the array. If the first search returned a positive result, the found
position is saved, and the FindNextBit (336) and FindPrevBit (336) will use this position to resume
the search. To start a search from a certain position, the start position can be set with the SetIndex
(335) instead.
Errors: None.
See also: FindNextBit (336), FindPrevBit (336), OpenBit (336), SetIndex (335)
335
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.40.19 TBits.FindNextBit
Synopsis: Searches the next bit with a particular value.
Declaration: function FindNextBit : LongInt
Visibility: public
Description: FindNextBit resumes a previously started search. It searches for the next bit with the value
specified in the FindFirstBit (335). The search is done towards the end of the array and starts at the
position last reported by one of the Find calls or at the position set with SetIndex (335).
If another bit with the same value is found, its position is returned. If no more bits with the same
value are present in the array, -1 is returned.
Errors: None.
See also: FindFirstBit (335), FindPrevBit (336), OpenBit (336), SetIndex (335)
4.40.20 TBits.FindPrevBit
Synopsis: Searches the previous bit with a particular value.
Declaration: function FindPrevBit : LongInt
Visibility: public
Description: FindPrevBit resumes a previously started search. It searches for the previous bit with the value
specified in the FindFirstBit (335). The search is done towards the beginning of the array and starts
at the position last reported by one of the Find calls or at the position set with SetIndex (335).
If another bit with the same value is found, its position is returned. If no more bits with the same
value are present in the array, -1 is returned.
Errors: None.
See also: FindFirstBit (335), FindNextBit (336), OpenBit (336), SetIndex (335)
4.40.21 TBits.OpenBit
Synopsis: Returns the position of the first bit that is set to False.
Declaration: function OpenBit : LongInt
Visibility: public
Description: OpenBit returns the position of the first bit whose value is 0 (False), or -1 if no open bit was
found. This call is equivalent to FindFirstBit(False), except that it doesn’t set the position
for the next searches.
Errors: None.
See also: FindNextBit (335), FindPrevBit (336), FindFirstBit (335), SetIndex (335)
336
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.40.22 TBits.Bits
Synopsis: Access to all bits in the array.
Declaration: Property Bits[Bit: LongInt]: Boolean; default
Visibility: public
Access: Read,Write
Description: Bits allows indexed access to all of the bits in the array. It gives True if the bit is 1, False
otherwise; Assigning to this property will set, respectively clear the bit.
Errors: If an index is specified which is out of the allowed range then an EBitsError (282) exception is
raised.
See also: Size (337)
4.40.23 TBits.Size
Synopsis: Current size of the array of bits.
Declaration: Property Size : LongInt
Visibility: public
Access: Read,Write
Description: Size is the current size of the bit array. Setting this property will adjust the size; this is equivalent
to calling Grow(Value-1)
Errors: If an invalid size (negative or too large) is specified, a EBitsError (282) exception is raised.
See also: Bits (337)
4.41 TBytesStream
4.41.1 Description
TBytesStream is a stream that uses an array of byte (TBytes (249)) to keep the stream data. it
overrides the TMemoryStream (397) memory allocation routine to use the array of bytes. The array
of bytes is exposed through the Bytes (249) property.
See also: TBytes (249), TMemoryStream (397), Bytes (249)
4.41.2 Method overview
Page Method Description
338 Create Create a new instance of the stream, initializing it with an array of bytes
4.41.3 Property overview
Page Properties Access Description
338 Bytes r The stream data as an array of bytes.
337
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.41.4 TBytesStream.Create
Synopsis: Create a new instance of the stream, initializing it with an array of bytes
Declaration: constructor Create(const ABytes: TBytes); Overload
Visibility: public
Description: Create creates a new instance and initializes the memory with the data in ABytes.
See also: TBytes (249), TMemoryStream (397), Bytes (249)
4.41.5 TBytesStream.Bytes
Synopsis: The stream data as an array of bytes.
Declaration: Property Bytes : TBytes
Visibility: public
Access: Read
Description: Bytes provides byte-sized access to the array of bytes that represent the stream data. As a pointer
value, it equals TCustomMemoryStream.Memory (362), meaning that Memory points to the first
byte in the array.
See also: TBytes (249), TMemoryStream (397), TCustomMemoryStream.Memory (362)
4.42 TCollection
4.42.1 Description
TCollection implements functionality to manage a collection of named objects. Each of these
objects needs to be a descendant of the TCollectionItem (346) class. Exactly which type of object is
managed can be seen from the TCollection.ItemClass (344) property.
Normally, no TCollection is created directly. Instead, a descendants of TCollection and
TCollectionItem (346) are created as a pair.
See also: TCollectionItem (346)
338
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.42.2 Method overview
Page Method Description
340 Add Creates and adds a new item to the collection.
340 Assign Assigns one collection to another.
340 BeginUpdate Start an update batch.
341 Clear Removes all items from the collection.
339 Create Creates a new collection.
341 Delete Delete an item from the collection.
339 Destroy Destroys the collection and frees all the objects it manages.
341 EndUpdate Ends an update batch.
343 Exchange Exchange 2 items in the collection
342 FindItemID Searches for an Item in the collection, based on its TCollectionItem.ID
(347) property.
342 GetEnumerator Create an IEnumerator instance
342 GetNamePath Overrides TPersistent.GetNamePath (410) to return a proper pathname.
342 Insert Insert an item in the collection.
340 Owner Owner of the collection.
343 Sort Sort the items in the collection
4.42.3 Property overview
Page Properties Access Description
343 Count r Number of items in the collection.
344 ItemClass r Class pointer for each item in the collection.
344 Items rw Indexed array of items in the collection.
4.42.4 TCollection.Create
Synopsis: Creates a new collection.
Declaration: constructor Create(AItemClass: TCollectionItemClass)
Visibility: public
Description: Create instantiates a new instance of the TCollection class which will manage objects of class
AItemClass. It creates the list used to hold all objects, and stores the AItemClass for the adding
of new objects to the collection.
See also: TCollection.ItemClass (344), TCollection.Destroy (339)
4.42.5 TCollection.Destroy
Synopsis: Destroys the collection and frees all the objects it manages.
Declaration: destructor Destroy; Override
Visibility: public
Description: Destroy first clears the collection, and then frees all memory allocated to this instance.
Don’t call Destroy directly, call Free instead.
See also: TCollection.Create (339)
339
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.42.6 TCollection.Owner
Synopsis: Owner of the collection.
Declaration: function Owner : TPersistent
Visibility: public
Description: Owner returns a reference to the owner of the collection. This property is required by the object
inspector to be able to show the collection.
4.42.7 TCollection.Add
Synopsis: Creates and adds a new item to the collection.
Declaration: function Add : TCollectionItem
Visibility: public
Description: Add instantiates a new item of class TCollection.ItemClass (344) and adds it to the list. The newly
created object is returned.
See also: TCollection.ItemClass (344), TCollection.Clear (341)
4.42.8 TCollection.Assign
Synopsis: Assigns one collection to another.
Declaration: procedure Assign(Source: TPersistent); Override
Visibility: public
Description: Assign assigns the contents of one collection to another. It does this by clearing the items list, and
adding as much elements as there are in the Source collection; it assigns to each created element
the contents of it’s counterpart in the Source element.
Two collections cannot be assigned to each other if instances of the ItemClass classes cannot be
assigned to each other.
Errors: If the objects in the collections cannot be assigned to one another, then an EConvertError is
raised.
See also: TPersistent.Assign (409), TCollectionItem (346)
4.42.9 TCollection.BeginUpdate
Synopsis: Start an update batch.
Declaration: procedure BeginUpdate; Virtual
Visibility: public
Description: BeginUpdate is called at the beginning of a batch update. It raises the update count with 1.
Call BeginUpdate at the beginning of a series of operations that will change the state of the
collection. This will avoid the call to TCollection.Update (338) for each operation. At the end of the
operations, a corresponding call to EndUpdate must be made. It is best to do this in the context of
a Try ... finally block:
340
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
With MyCollection Do
try
BeginUpdate;
// Some Lengthy operations
finally
EndUpdate;
end;
This insures that the number of calls to BeginUpdate always matches the number of calls to
TCollection.EndUpdate (341), even in case of an exception.
See also: TCollection.EndUpdate (341), TCollection.Changed (338), TCollection.Update (338)
4.42.10 TCollection.Clear
Synopsis: Removes all items from the collection.
Declaration: procedure Clear
Visibility: public
Description: Clear will clear the collection, i.e. each item in the collection is destroyed and removed from
memory. After a call to Clear, Count is zero.
See also: TCollection.Add (340), TCollectionItem.Destroy (346), TCollection.Destroy (339)
4.42.11 TCollection.EndUpdate
Synopsis: Ends an update batch.
Declaration: procedure EndUpdate; Virtual
Visibility: public
Description: EndUpdate signals the end of a series of operations that change the state of the collection, possibly
triggering an update event. It does this by decreasing the update count with 1 and calling TCollec-
tion.Changed (338) it should always be used in conjunction with TCollection.BeginUpdate (340),
preferably in the Finally section of a Try ... Finally block.
See also: TCollection.BeginUpdate (340), TCollection.Changed (338), TCollection.Update (338)
4.42.12 TCollection.Delete
Synopsis: Delete an item from the collection.
Declaration: procedure Delete(Index: Integer)
Visibility: public
Description: Delete deletes the item at (zero based) position Index from the collection. This will result in a
cnDeleted notification.
Errors: If an invalid index is specified, an EListError exception is raised.
See also: TCollection.Items (344), TCollection.Insert (342), TCollection.Clear (341)
341
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.42.13 TCollection.GetEnumerator
Synopsis: Create an IEnumerator instance
Declaration: function GetEnumerator : TCollectionEnumerator
Visibility: public
Description: GetEnumerator is the implementation of the IEnumerable (1521) interface for TCollection.
It creates a TCollectionEnumerator (344) instance and returns it’s IEnumerator (1521) interface.
See also: TCollectionEnumerator (344), IEnumerator (1521), IEnumerable (1521)
4.42.14 TCollection.GetNamePath
Synopsis: Overrides TPersistent.GetNamePath (410) to return a proper pathname.
Declaration: function GetNamePath : string; Override
Visibility: public
Description: GetNamePath returns the name path for this collection. If the following conditions are satisfied:
1.There is an owner object.
2.The owner object returns a non-empty name path.
3.The TCollection.Propname (338) property is not empty
collection has an owner and the owning object has a name, then the function returns the owner name,
followed by the propname. If one of the conditions is not satisfied, then the classname is returned.
See also: TCollection.GetOwner (338), TCollection.Propname (338)
4.42.15 TCollection.Insert
Synopsis: Insert an item in the collection.
Declaration: function Insert(Index: Integer) : TCollectionItem
Visibility: public
Description: Insert creates a new item instance and inserts it in the collection at position Index, and returns
the new instance.
In contrast, TCollection.Add (340) adds a new item at the end.
Errors: None.
See also: TCollection.Add (340), TCollection.Delete (341), TCollection.Items (344)
4.42.16 TCollection.FindItemID
Synopsis: Searches for an Item in the collection, based on its TCollectionItem.ID (347) property.
Declaration: function FindItemID(ID: Integer) : TCollectionItem
Visibility: public
342
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
Description: FindItemID searches through the collection for the item that has a value of ID for its TCollec-
tionItem.ID (347) property, and returns the found item. If no such item is found in the collection,
Nil is returned.
The routine performs a linear search, so this can be slow on very large collections.
See also: TCollection.Items (344), TCollectionItem.ID (347)
4.42.17 TCollection.Exchange
Synopsis: Exchange 2 items in the collection
Declaration: procedure Exchange(const Index1: Integer; const index2: Integer)
Visibility: public
Description: Exchange exchanges the items at indexes Index1 and Index2 in the collection.
Errors: If one of the two indexes is invalid (less than zero or larger than the number of items) an EListError
exception is raised.
See also: Items (344), TCollectionItem.Index (348)
4.42.18 TCollection.Sort
Synopsis: Sort the items in the collection
Declaration: procedure Sort(const Compare: TCollectionSortCompare)
Visibility: public
Description: Sort sorts the items in the collection, and uses the Compare procedure to compare 2 items in the
collection. It is more efficient do use this method than to perform the sort manually, because the list
items are manipulated directly.
For more information on how the Compare function should behave, see the TCollectionSortCom-
pare (254) type.
See also: TCollectionSortCompare (254)
4.42.19 TCollection.Count
Synopsis: Number of items in the collection.
Declaration: Property Count : Integer
Visibility: public
Access: Read
Description: Count contains the number of items in the collection.
Remark: The items in the collection are identified by their TCollectionItem.Index (348) property, which is a
zero-based index, meaning that it can take values between 0 and Count-1, borders included.
See also: TCollectionItem.Index (348), TCollection.Items (344)
343
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.42.20 TCollection.ItemClass
Synopsis: Class pointer for each item in the collection.
Declaration: Property ItemClass : TCollectionItemClass
Visibility: public
Access: Read
Description: ItemClass is the class pointer with which each new item in the collection is created. It is the
value that was passed to the collection’s constructor when it was created, and does not change during
the lifetime of the collection.
See also: TCollectionItem (346), TCollection.Items (344)
4.42.21 TCollection.Items
Synopsis: Indexed array of items in the collection.
Declaration: Property Items[Index: Integer]: TCollectionItem
Visibility: public
Access: Read,Write
Description: Items provides indexed access to the items in the collection. Since the array is zero-based, Index
should be an integer between 0 and Count-1.
It is possible to set or retrieve an element in the array. When setting an element of the array, the
object that is assigned should be compatible with the class of the objects in the collection, as given
by the TCollection.ItemClass (344) property.
Adding an element to the array can be done with the TCollection.Add (340) method. The array can
be cleared with the TCollection.Clear (341) method. Removing an element of the array should be
done by freeing that element.
See also: TCollection.Count (343), TCollection.ItemClass (344), TCollection.Clear (341), TCollection.Add
(340)
4.43 TCollectionEnumerator
4.43.1 Description
TCollectionEnumerator implements the #rtl.system.IEnumerator (1521) interface for the TCol-
lection (338) class, so the TCollection class can be used in a for ... in loop. It is returned
by the TCollection.GetEnumerator (342) method of TCollection.
See also: TCollection (338), TCollection.GetEnumerator (342), #rtl.system.IEnumerator (1521)
4.43.2 Method overview
Page Method Description
345 Create Initialize a new instance of TCollectionEnumerator
345 GetCurrent Return the current pointer in the list
345 MoveNext Move the position of the enumerator to the next position in the collection.
344
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.43.3 Property overview
Page Properties Access Description
345 Current r Current pointer in the list
4.43.4 TCollectionEnumerator.Create
Synopsis: Initialize a new instance of TCollectionEnumerator
Declaration: constructor Create(ACollection: TCollection)
Visibility: public
Description: Create initializes a new instance of TCollectionEnumerator and keeps a reference to the
collection ACollection that will be enumerated.
See also: TCollection (338)
4.43.5 TCollectionEnumerator.GetCurrent
Synopsis: Return the current pointer in the list
Declaration: function GetCurrent : TCollectionItem
Visibility: public
Description: GetCurrent returns the current TCollectionItem (346) instance in the enumerator.
Errors: No checking is done on the validity of the current position.
See also: MoveNext (345), TCollectionItem (346)
4.43.6 TCollectionEnumerator.MoveNext
Synopsis: Move the position of the enumerator to the next position in the collection.
Declaration: function MoveNext : Boolean
Visibility: public
Description: MoveNext puts the pointer on the next item in the collection, and returns True if this succeeded,
or False if the pointer is past the last element in the list.
Errors: Note that if False is returned, calling GetCurrent will result in an exception.
See also: GetCurrent (345)
4.43.7 TCollectionEnumerator.Current
Synopsis: Current pointer in the list
Declaration: Property Current : TCollectionItem
Visibility: public
Access: Read
Description: Current redefines GetCurrent (345) as a property.
See also: GetCurrent (345)
345
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.44 TCollectionItem
4.44.1 Description
TCollectionItem and TCollection (338) form a pair of base classes that manage a collection
of named objects. The TCollectionItem is the named object that is managed, it represents one
item in the collection. An item in the collection is represented by three properties: TCollection-
Item.DisplayName (348), TCollection.Index (338) and TCollectionItem.ID (347).
A TCollectionItem object is never created directly. To manage a set of named items, it is
necessary to make a descendant of TCollectionItem to which needed properties and methods
are added. This descendant can then be managed with a TCollection (338) class. The managing
collection will create and destroy it’s items by itself, it should therefore never be necessary to create
TCollectionItem descendants manually.
See also: TCollection (338)
4.44.2 Method overview
Page Method Description
346 Create Creates a new instance of this collection item.
346 Destroy Destroyes this collection item.
347 GetNamePath Returns the namepath of this collection item.
4.44.3 Property overview
Page Properties Access Description
347 Collection rw Pointer to the collection managing this item.
348 DisplayName rw Name of the item, displayed in the object inspector.
347 ID r Initial index of this item.
348 Index rw Index of the item in its managing collection TCollection.Items
(344) property.
4.44.4 TCollectionItem.Create
Synopsis: Creates a new instance of this collection item.
Declaration: constructor Create(ACollection: TCollection); Virtual
Visibility: public
Description: Create instantiates a new item in a TCollection (338). It is called by the TCollection.Add (340)
function and should under normal circumstances never be called directly. called
See also: TCollectionItem.Destroy (346)
4.44.5 TCollectionItem.Destroy
Synopsis: Destroyes this collection item.
Declaration: destructor Destroy; Override
Visibility: public
346
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
Description: Destroy removes the item from the managing collection and Destroys the item instance.
This is the only way to remove items from a collection;
See also: TCollectionItem.Create (346)
4.44.6 TCollectionItem.GetNamePath
Synopsis: Returns the namepath of this collection item.
Declaration: function GetNamePath : string; Override
Visibility: public
Description: GetNamePath overrides the TPersistent.GetNamePath (410) method to return the name of the
managing collection and appends its TCollectionItem.Index (348) property.
See also: TCollectionItem.Collection (347), TPersistent.GetNamePath (410), TCollectionItem.Index (348)
4.44.7 TCollectionItem.Collection
Synopsis: Pointer to the collection managing this item.
Declaration: Property Collection : TCollection
Visibility: public
Access: Read,Write
Description: Collection points to the collection managing this item. This property can be set to point to a
new collection. If this is done, the old collection will be notified that the item should no longer be
managed, and the new collection is notified that it should manage this item as well.
See also: TCollection (338)
4.44.8 TCollectionItem.ID
Synopsis: Initial index of this item.
Declaration: Property ID : Integer
Visibility: public
Access: Read
Description: ID is the initial value of TCollectionItem.Index (348); it doesn’t change after the index changes. It
can be used to uniquely identify the item. The ID property doesn’t change as items are added and
removed from the collection.
While the TCollectionItem.Index (348) property forms a continuous series, ID does not. If items are
removed from the collection, their ID is not used again, leaving gaps. Only when the collection is
initialiiy created, the ID and Index properties will be equal.
See also: TCollection.Items (344), TCollectionItem.Index (348)
347
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.44.9 TCollectionItem.Index
Synopsis: Index of the item in its managing collection TCollection.Items (344) property.
Declaration: Property Index : Integer
Visibility: public
Access: Read,Write
Description: Index is the current index of the item in its managing collection’s TCollection.Items (344) property.
This property may change as items are added and removed from the collection.
The index of an item is zero-based, i.e. the first item has index zero. The last item has index
Count-1 where Count is the number of items in the collection.
The Index property of the items in a collection form a continuous series ranging from 0 to Count-1.
The TCollectionItem.ID (347) property does not form a continuous series, but can also be used to
identify an item.
See also: TCollectionItem.ID (347), TCollection.Items (344)
4.44.10 TCollectionItem.DisplayName
Synopsis: Name of the item, displayed in the object inspector.
Declaration: Property DisplayName : string
Visibility: public
Access: Read,Write
Description: DisplayName contains the name of this item as shown in the object inspector. For TCollectionItem
this returns always the class name of the managing collection, followed by the index of the item.
TCollectionItem does not implement any functionality to store the DisplayName property.
The property can be set, but this will have no effect other than that the managing collection is no-
tified of a change. The actual displayname will remain unchanged. To store the DisplayName
property,TCollectionItem descendants should override the TCollectionItem.SetDisplayName
(346) and TCollectionItem.GetDisplayName (346) to add storage functionality.
See also: TCollectionItem.Index (348), TCollectionItem.ID (347), TCollectionItem.GetDisplayName (346),
TCollectionItem.SetDisplayName (346)
4.45 TComponent
4.45.1 Description
TComponent is the base class for any set of classes that needs owner-owned functionality, and
which needs support for property streaming. All classes that should be handled by an IDE (Inte-
grated Development Environment) must descend from TComponent, as it includes all support for
streaming all its published properties.
Components can ’own’ other components. TComponent introduces methods for enumerating the
child components. It also allows to name the owned components with a unique name. Furthermore,
functionality for sending notifications when a component is removed from the list or removed from
memory alltogether is also introduced in TComponent
TComponent introduces a form of automatic memory management: When a component is de-
stroyed, all its child components will be destroyed first.
348
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.45.2 Interfaces overview
Page Interfaces Description
289 IInterfaceComponentReference Interface for checking component references
1523 IUnknown Basic interface for all COM-based interfaces
4.45.3 Method overview
Page Method Description
351 BeforeDestruction Overrides standard BeforeDestruction.
350 Create Creates a new instance of the component.
351 Destroy Destroys the instance of the component.
351 DestroyComponents Destroy child components.
351 Destroying Called when the component is being destroyed
352 ExecuteAction Standard action execution method.
352 FindComponent Finds and returns the named component in the owned compo-
nents.
352 FreeNotification Ask the component to notify called when it is being destroyed.
353 FreeOnRelease Part of the IVCLComObject interface.
353 GetEnumerator Create an IEnumerator instance
353 GetNamePath Returns the name path of this component.
353 GetParentComponent Returns the parent component.
354 HasParent Does the component have a parent ?
354 InsertComponent Insert the given component in the list of owned components.
355 IsImplementorOf Checks if the current component is the implementor of the
interface
350 Notification Called by components that are freed and which received a
FreeNotification.
355 ReferenceInterface Interface implementation of Notification
354 RemoveComponent Remove the given component from the list of owned compo-
nents.
352 RemoveFreeNotification Remove a component from the Free Notification list.
354 SafeCallException Part of the IVCLComObject Interface.
355 SetSubComponent Sets the csSubComponent style.
355 UpdateAction Updates the state of an action.
350 WriteState Writes the component to a stream.
4.45.4 Property overview
Page Properties Access Description
356 ComObject r Interface reference implemented by the component
356 ComponentCount r Count of owned components
356 ComponentIndex rw Index of component in it’s owner’s list.
356 Components r Indexed list (zero-based) of all owned components.
357 ComponentState r Current component’s state.
357 ComponentStyle r Current component’s style.
357 DesignInfo rw Information for IDE designer.
358 Name rws Name of the component.
358 Owner r Owner of this component.
358 Tag rw Tag value of the component.
358 VCLComObject rw Not implemented.
349
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.45.5 TComponent.Notification
Synopsis: Called by components that are freed and which received a FreeNotification.
Declaration: procedure Notification(AComponent: TComponent; Operation: TOperation)
; Virtual
Visibility: protected
Description: Notification is called whenever a child component is destroyed, inserted or removed from the
list of owned component. Components that were requested to send a notification when they are freed
((with FreeNotification (352)) will also call Notification when they are freed.
The AComponent parameter specifies which component sends the notification, and Operation
specifies whether the component is being inserted into or removed from the child component list, or
whether it is being destroyed.
Descendants of TComponent can use FreeNotification (352) to request notification of the destruc-
tion of another object. By overriding the Notification method, they can do special process-
ing (typically, set a reference to this component to Nil) when this component is destroyed. The
Notification method is called quite often in the streaming process, so speed should be a con-
sideration when overriding this method.
See also: TOperation (260), TComponent.FreeNotification (352), TComponent.RemoveFreeNotification (352)
4.45.6 TComponent.WriteState
Synopsis: Writes the component to a stream.
Declaration: procedure WriteState(Writer: TWriter); Virtual
Visibility: public
Description: WriteState writes the component’s current state to a stream through the writer (484) object
writer. Values for all published properties of the component can be written to the stream. Normally
there is no need to call WriteState directly. The streaming system calls WriteState itself.
The TComponent (348) implementation of WriteState simply calls TWriter.WriteData (484).
Descendant classes can, however, override WriteStateto provide additional processing of stream
data.
See also: ReadState (348), TStream.WriteComponent (432), TWriter.WriteData (484)
4.45.7 TComponent.Create
Synopsis: Creates a new instance of the component.
Declaration: constructor Create(AOwner: TComponent); Virtual
Visibility: public
Description: Create creates a new instance of a TComponent class. If AOwner is not Nil, the new compo-
nent attempts to insert itself in the list of owned components of the owner.
See also: Insert (348), Owner (358)
350
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.45.8 TComponent.Destroy
Synopsis: Destroys the instance of the component.
Declaration: destructor Destroy; Override
Visibility: public
Description: Destroy sends a opRemove notification to all components in the free-notification list. After that,
all owned components are destroyed by calling DestroyComponents (351) (and hence removed from
the list of owned components). When this is done, the component removes itself from its owner’s
child component list. After that, the parent’s destroy method is called.
See also: Notification (350), Owner (358), DestroyComponents (351), Components (356)
4.45.9 TComponent.BeforeDestruction
Synopsis: Overrides standard BeforeDestruction.
Declaration: procedure BeforeDestruction; Override
Visibility: public
Description: BeforeDestruction is overridden by TComponent to set the csDestroying flag in TCom-
ponent.ComponentState (357)
See also: TComponent.ComponentState (357)
4.45.10 TComponent.DestroyComponents
Synopsis: Destroy child components.
Declaration: procedure DestroyComponents
Visibility: public
Description: DestroyComponents calls the destructor of all owned components, till no more components are
left in the Components (356) array.
Calling the destructor of an owned component has as the effect that the component will remove itself
from the list of owned components, if nothing has disrupted the sequence of destructors.
Errors: If an overridden ’destroy’ method does not call it’s intherited destructor or raises an exception, it’s
TComponent.Destroy (351) destructor will not be called, which may result in an endless loop.
See also: Destroy (351), Components (356)
4.45.11 TComponent.Destroying
Synopsis: Called when the component is being destroyed
Declaration: procedure Destroying
Visibility: public
Description: Destroying sets the csDestroying flag in the component’s state (348) property, and does the
same for all owned components.
It is not necessary to call Destroying directly, the destructor Destroy (351) does this automatically.
See also: State (348), Destroy (351)
351
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.45.12 TComponent.ExecuteAction
Synopsis: Standard action execution method.
Declaration: function ExecuteAction(Action: TBasicAction) : Boolean; Dynamic
Visibility: public
Description: ExecuteAction checks whether Action handles the current component, and if yes, calls the
ExecuteAction method, passing itself as a parameter. The function returns True if the action
handles the current component.
See also: TBasicAction (312), TBasicAction.ExecuteAction (312), TBasicAction.HandlesTarget (313), TCom-
ponent.UpdateAction (355)
4.45.13 TComponent.FindComponent
Synopsis: Finds and returns the named component in the owned components.
Declaration: function FindComponent(const AName: string) : TComponent
Visibility: public
Description: FindComponent searches the component with name AName in the list of owned components. If
AName is empty, then Nil is returned.
See also: Components (356), Name (358)
4.45.14 TComponent.FreeNotification
Synopsis: Ask the component to notify called when it is being destroyed.
Declaration: procedure FreeNotification(AComponent: TComponent)
Visibility: public
Description: FreeNotification inserts AComponent in the freenotification list. When the component is
destroyed, the Notification (350) method is called for all components in the freenotification list.
See also: Components (356), Notification (350), TComponent.RemoveFreeNotification (352)
4.45.15 TComponent.RemoveFreeNotification
Synopsis: Remove a component from the Free Notification list.
Declaration: procedure RemoveFreeNotification(AComponent: TComponent)
Visibility: public
Description: RemoveFreeNotification removes AComponent from the freenotification list.
See also: TComponent.FreeNotification (352)
352
CHAPTER 4. REFERENCE FOR UNIT ’CLASSES’
4.45.16 TComponent.FreeOnRelease
Synopsis: Part of the IVCLComObject interface.
Declaration: procedure FreeOnRelease
Visibility: public
Description: Provided for Delphi compatibility, but is not yet implemented.
4.45.17 TComponent.GetEnumerator
Synopsis: Create an IEnumerator instance
Declaration: function GetEnumerator : TComponentEnumerator
Visibility: public
Description: GetEnumerator is the implementation of the IEnumerable (1521) interface for TComponent. It
creates a TComponentEnumerator (359) instance and returns it’s IEnumerator (1521) interface. The
enumerator enumerates all child components of the component instance.
See also: TComponentEnumerator (359), IEnumerator (1521), IEnumerable (1521)
4.45.18 TComponent