[Wisp-cvs] wisp/users/dig winapi.tran,1.8,1.9
Status: Alpha
Brought to you by:
digg
From: <di...@us...> - 2003-05-21 14:33:22
|
Update of /cvsroot/wisp/wisp/users/dig In directory sc8-pr-cvs1:/tmp/cvs-serv25062 Modified Files: winapi.tran Log Message: wrapped CreateFile* Index: winapi.tran =================================================================== RCS file: /cvsroot/wisp/wisp/users/dig/winapi.tran,v retrieving revision 1.8 retrieving revision 1.9 diff -u -d -r1.8 -r1.9 --- winapi.tran 21 May 2003 13:20:09 -0000 1.8 +++ winapi.tran 21 May 2003 14:33:17 -0000 1.9 @@ -30,4 +30,54 @@ :[ ] FreeConsole \ ( -- success? ) commit 'FreeConsole@kernel32 $call %eax ; +\ flags for the share-mode argument of CreateFile* +:[ ] FILE_SHARE_READ 1 ; +:[ ] FILE_SHARE_WRITE 2 ; +:[ ] FILE_SHARE_DELETE 4 ; \ Not supported in MSW ME/98/95 + +\ values for the creation-disposition argument of CreateFile* +:[ ] CREATE_NEW 1 ; +:[ ] CREATE_ALWAYS 2 ; +:[ ] OPEN_EXISTING 3 ; +:[ ] OPEN_ALWAYS 4 ; +:[ ] TRUNCATE_EXISTING 5 ; + +\ attributes for the flags-and-attrs argument of CreateFile* +:[ ] FILE_ATTRIBUTE_READONLY 1 ; +:[ ] FILE_ATTRIBUTE_HIDDEN 2 ; +:[ ] FILE_ATTRIBUTE_SYSTEM 4 ; +:[ ] FILE_ATTRIBUTE_ARCHIVE 32 ; +:[ ] FILE_ATTRIBUTE_NORMAL 128 ; \ valid only if used alone +:[ ] FILE_ATTRIBUTE_TEMPORARY 256 ; +:[ ] FILE_ATTRIBUTE_OFFLINE 4096 ; + +\ flags for the flags-and-attrs argument of CreateFile* +:[ ] FILE_FLAG_BACKUP_SEMANTICS 33554432 ; +:[ ] FILE_FLAG_DELETE_ON_CLOSE 67108864 ; +:[ ] FILE_FLAG_NO_BUFFERING 536870912 ; +:[ ] FILE_FLAG_OVERLAPPED 1073741824 ; +:[ ] FILE_FLAG_POSIX_SEMANTICS 16777216 ; +:[ ] FILE_FLAG_RANDOM_ACCESS 268435456 ; \ optimization hint +:[ ] FILE_FLAG_SEQUENTIAL_SCAN 134217728 ; \ optimization hint +:[ ] FILE_FLAG_WRITE_THROUGH 0x80000000 ; + +\ yet more bits for the flags-and-attrs argument of CreateFile* +:[ ] SECURITY_SQOS_PRESENT 1048576 ; +:[ ] SECURITY_ANONYMOUS 0 ; +:[ ] SECURITY_CONTEXT_TRACKING 262144 ; +:[ ] SECURITY_DELEGATION 196608 ; +:[ ] SECURITY_EFFECTIVE_ONLY 524288 ; +:[ ] SECURITY_IDENTIFICATION 65536 ; +:[ ] SECURITY_IMPERSONATION 131072 ; + +:[ ] CreateFileA \ ( filename desired-access share-mode security-attr + \ creation-disposition flags-and-attrs template-handle + \ -- handle ) + 7rev commit 'CreateFileA@kernel32 $call %eax ; + +:[ ] CreateFileW \ ( filename desired-access share-mode security-attr + \ creation-disposition flags-and-attrs template-handle + \ -- handle ) + 7rev commit 'CreateFileW@kernel32 $call %eax ; + \ vim: ft=tran |