mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-10 12:32:20 +02:00
Revamp Stdcall
This commit is contained in:
parent
7b4239d08e
commit
ad0dab0d4c
58 changed files with 1398 additions and 1398 deletions
|
@ -359,7 +359,7 @@ namespace System
|
|||
}
|
||||
}
|
||||
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
static extern int32 ftoa(float val, char8* str);
|
||||
|
||||
static extern int32 ToString(float val, char8* str);
|
||||
|
|
|
@ -44,21 +44,21 @@ namespace System
|
|||
TempFileError = (int)Result.TempFileError
|
||||
}
|
||||
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern uint32 BfpSystem_TickCount();
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpSystem_GetEnvironmentStrings(char8* outStr, int32* inOutStrSize, BfpSystemResult* outResult);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern uint32 BfpSystem_InterlockedExchange32(uint32* ptr, uint32 val); // Returns the initial value in 'ptr'
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern uint64 BfpSystem_InterlockedExchange64(uint64* ptr, uint64 val);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern uint32 BfpSystem_InterlockedExchangeAdd32(uint32* ptr, uint32 val); // Returns the initial value in 'ptr'
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern uint64 BfpSystem_InterlockedExchangeAdd64(uint64* ptr, uint64 val);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern uint32 BfpSystem_InterlockedCompareExchange32(uint32* ptr, uint32 oldVal, uint32 newVal);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern uint64 BfpSystem_InterlockedCompareExchange64(uint64* ptr, uint64 oldVal, uint64 newVal);
|
||||
|
||||
public enum BfpFileWatcherFlags : int32
|
||||
|
@ -78,9 +78,9 @@ namespace System
|
|||
|
||||
public function void BfpDirectoryChangeFunc(BfpFileWatcher* watcher, void* userData, BfpFileChangeKind changeKind, char8* directory, char8* fileName, char8* oldName);
|
||||
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern BfpFileWatcher* BfpFileWatcher_WatchDirectory(char8* path, BfpDirectoryChangeFunc callback, BfpFileWatcherFlags flags, void* userData, BfpFileResult* outResult);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpFileWatcher_Release(BfpFileWatcher* fileWatcher);
|
||||
|
||||
public enum BfpProcessResult
|
||||
|
@ -89,19 +89,19 @@ namespace System
|
|||
InsufficientBuffer = (int)Result.InsufficientBuffer
|
||||
}
|
||||
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern bool BfpProcess_IsRemoteMachine(char8* machineName);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern BfpProcess* BfpProcess_GetById(char8* machineName, int32 processId, BfpProcessResult* outResult);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpProcess_Enumerate(char8* machineName, BfpProcess** outProcesses, int32* inOutProcessesSize, BfpProcessResult* outResult);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpProcess_Release(BfpProcess* process);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpProcess_GetMainWindowTitle(BfpProcess* process, char8* outTitle, int32* inOutTitleSize, BfpProcessResult* outResult);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpProcess_GetProcessName(BfpProcess* process, char8* outName, int32* inOutNameSize, BfpProcessResult* outResult);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern int32 BfpProcess_GetProcessId(BfpProcess* process);
|
||||
|
||||
public enum BfpSpawnFlags
|
||||
|
@ -134,29 +134,29 @@ namespace System
|
|||
UnknownError = (int)Result.UnknownError
|
||||
};
|
||||
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern BfpSpawn* BfpSpawn_Create(char8* targetPath, char8* args, char8* workingDir, char8* env, BfpSpawnFlags flags, BfpSpawnResult* outResult);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpSpawn_Release(BfpSpawn* spawn);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpSpawn_Kill(BfpSpawn* spawn, int32 exitCode, BfpKillFlags killFlags, BfpSpawnResult* outResult);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern bool BfpSpawn_WaitFor(BfpSpawn* spawn, int waitMS, int* outExitCode, BfpSpawnResult* outResult);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpSpawn_GetStdHandles(BfpSpawn* spawn, BfpFile** outStdIn, BfpFile** outStdOut, BfpFile** outStdErr);
|
||||
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern int BfpProcess_GetCurrentId();
|
||||
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern BfpCritSect* BfpCritSect_Create();
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpCritSect_Release(BfpCritSect* critSect);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpCritSect_Enter(BfpCritSect* critSect);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern bool BfpCritSect_TryEnter(BfpCritSect* critSect, int32 waitMS);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpCritSect_Leave(BfpCritSect* critSect);
|
||||
|
||||
public enum BfpEventFlags : int32
|
||||
|
@ -174,15 +174,15 @@ namespace System
|
|||
BfpEventResult_NotSupported = (int)Result.NotSupported
|
||||
};
|
||||
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern BfpEvent* BfpEvent_Create(BfpEventFlags flags);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpEvent_Release(BfpEvent* event);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpEvent_Set(BfpEvent* event, bool requireManualReset);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpEvent_Reset(BfpEvent* event, BfpEventResult* outResult);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern bool BfpEvent_WaitFor(BfpEvent* event, int32 waitMS);
|
||||
|
||||
public enum BfpLibResult : int32
|
||||
|
@ -192,13 +192,13 @@ namespace System
|
|||
InsufficientBuffer = (int)Result.InsufficientBuffer
|
||||
};
|
||||
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern BfpDynLib* BfpDynLib_Load(char8* fileName);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpDynLib_Release(BfpDynLib* lib);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpDynLib_GetFilePath(BfpDynLib* lib, char8* outPath, int32* inOutPathSize, BfpLibResult* outResult);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void* BfpDynLib_GetProcAddress(BfpDynLib* lib, char8* name);
|
||||
|
||||
public enum BfpFileResult : int32
|
||||
|
@ -216,17 +216,17 @@ namespace System
|
|||
InsufficientBuffer = (int)Result.InsufficientBuffer
|
||||
};
|
||||
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpDirectory_Create(char8* name, BfpFileResult* outResult);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpDirectory_Rename(char8* oldName, char8* newName, BfpFileResult* outResult);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpDirectory_Delete(char8* name, BfpFileResult* outResult);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpDirectory_GetCurrent(char8* outPath, int32* inOutPathSize, BfpFileResult* outResult);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpDirectory_SetCurrent(char8* path, BfpFileResult* outResult);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern bool BfpDirectory_Exists(char8* path);
|
||||
|
||||
public enum BfpFileCreateKind : int32
|
||||
|
@ -288,43 +288,43 @@ namespace System
|
|||
IfNewer,
|
||||
};
|
||||
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern BfpFile* BfpFile_Create(char8* name, BfpFileCreateKind createKind, BfpFileCreateFlags createFlags, BfpFileAttributes createdFileAttrs, BfpFileResult* outResult);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpFile_Release(BfpFile* file);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern int BfpFile_Write(BfpFile* file, void* buffer, int size, int timeoutMS, BfpFileResult* outResult);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern int BfpFile_Read(BfpFile* file, void* buffer, int size, int timeoutMS, BfpFileResult* outResult);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpFile_Flush(BfpFile* file);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern int64 BfpFile_GetFileSize(BfpFile* file);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern int64 BfpFile_Seek(BfpFile* file, int64 offset, BfpFileSeekKind seekKind);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpFile_Truncate(BfpFile* file);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern BfpTimeStamp BfpFile_GetTime_LastWrite(char8* path);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern BfpFileAttributes BfpFile_GetAttributes(char8* path, BfpFileResult* outResult);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpFile_SetAttributes(char8* path, BfpFileAttributes attribs, BfpFileResult* outResult);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpFile_Copy(char8* oldPath, char8* newPath, BfpFileCopyKind copyKind, BfpFileResult* outResult);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpFile_Rename(char8* oldPath, char8* newPath, BfpFileResult* outResult);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpFile_Delete(char8* path, BfpFileResult* outResult);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern bool BfpFile_Exists(char8* path);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpFile_GetTempPath(char8* outPath, int32* inOutPathSize, BfpFileResult* outResult);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpFile_GetTempFileName(char8* outName, int32* inOutNameSize, BfpFileResult* outResult);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpFile_GetFullPath(char8* inPath, char8* outPath, int32* inOutPathSize, BfpFileResult* outResult);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpFile_GetActualPath(char8* inPath, char8* outPath, int32* inOutPathSize, BfpFileResult* outResult);
|
||||
|
||||
public enum BfpFindFileFlags : int32
|
||||
|
@ -334,21 +334,21 @@ namespace System
|
|||
Directories = 2,
|
||||
};
|
||||
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern BfpFindFileData* BfpFindFileData_FindFirstFile(char8* path, BfpFindFileFlags flags, BfpFileResult* outResult);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern bool BfpFindFileData_FindNextFile(BfpFindFileData* findData);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpFindFileData_GetFileName(BfpFindFileData* findData, char8* outName, int32* inOutNameSize, BfpFileResult* outResult);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern BfpTimeStamp BfpFindFileData_GetTime_LastWrite(BfpFindFileData* findData);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern BfpTimeStamp BfpFindFileData_GetTime_Created(BfpFindFileData* findData);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern BfpTimeStamp BfpFindFileData_GetTime_Access(BfpFindFileData* findData);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern BfpFileAttributes BfpFindFileData_GetFileAttributes(BfpFindFileData* findData);
|
||||
[StdCall, CLink]
|
||||
[CallingConvention(.Stdcall), CLink]
|
||||
public static extern void BfpFindFileData_Release(BfpFindFileData* findData);
|
||||
|
||||
public enum SysDirectory : int32
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue