系統Api中型別與C 型別對應表

2021-05-24 02:35:25 字數 1360 閱讀 9428

2011-01-12

wtypes.h 中的非託管型別

非託管 c 語言型別

託管類名

說明 handle

void*

system.intptr

在 32 位 windows 作業系統上為 32 位,在 64 位 windows 作業系統上為 64 位。

byte

unsigned char

system.byte

8 位short

short

system.int16

16 位

word

unsigned short

system.uint16

16 位

int

int

system.int32

32 位

uint

unsigned int

system.uint32

32 位

long

long

system.int32

32 位

bool

long

system.int32

32 位

dword

unsigned long

system.uint32

32 位

ulong

unsigned long

system.uint32

32 位

char

char

system.char

用 ansi 修飾。

lpstr

char*

system.string 或 system.text.stringbuilder

用 ansi 修飾。

lpcstr

const char*

system.string 或 system.text.stringbuilder

用 ansi 修飾。

lpwstr

wchar_t*

system.string 或 system.text.stringbuilder

用 unicode 修飾。

lpcwstr

const wchar_t*

system.string 或 system.text.stringbuilder

用 unicode 修飾。

float

float

system.single

32 位

double

double

system.double

64 位

API與C 的資料型別對應關係表 zt

api與c 的資料型別對應關係表 api資料型別 型別描述 c 型別 api資料型別 型別描述 c 型別 word 16位無符號整數 ushort char 字元char long 32位無符號整數 intdwordlong 64位長整數 long dword 32位無符號整數 uint hdc裝置...

Swift與C型別對應關係表

每乙個 c 語言基本型別,swift 都提供了與之對應的型別。在 swift 中呼叫 c 方法的時候,會用到這些型別 c 型別 swift 對應型別 別名bool cbool bool char,unsigned char cchar,cunsignedchar int8,uint8 short,u...

c與Pascal型別對應

c語言的函式格式與delphi不同,它們是函式返回型別在前,函式宣告在後.對於沒有任何返回型別的函式則定義為void型別.例如 delphi中函式function myfunction intin integer bool 相應的c語言 就變成bool myfunction int intin 又例...