Mercurial > projects > dstep
comparison dstep/corefoundation/CFNumber.d @ 11:07194b026fa4
Added bindings to a couple of frameworks, new license + some other things
author | Jacob Carlborg <doob@me.com> |
---|---|
date | Sat, 01 Aug 2009 15:03:28 +0200 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
10:27e00625790b | 11:07194b026fa4 |
---|---|
1 /** | |
2 * Copyright: Copyright (c) 2009 Jacob Carlborg. | |
3 * Authors: Jacob Carlborg | |
4 * Version: Initial created: Jul 12, 2009 | |
5 * License: $(LINK2 http://www.boost.org/LICENSE_1_0.txt, Boost Software License 1.0) | |
6 */ | |
7 module dstep.corefoundation.CFNumber; | |
8 | |
9 import dstep.corefoundation.CFBase; | |
10 import dstep.objc.bridge.Bridge; | |
11 import dstep.objc.objc : id; | |
12 | |
13 struct __CFBoolean; | |
14 alias __CFBoolean* CFBooleanRef; | |
15 alias int CFNumberType; | |
16 struct __CFNumber; | |
17 alias __CFNumber* CFNumberRef; | |
18 | |
19 extern (C) | |
20 { | |
21 extern | |
22 { | |
23 const CFBooleanRef kCFBooleanTrue; | |
24 const CFBooleanRef kCFBooleanFalse; | |
25 const CFNumberRef kCFNumberPositiveInfinity; | |
26 const CFNumberRef kCFNumberNegativeInfinity; | |
27 const CFNumberRef kCFNumberNaN; | |
28 } | |
29 } | |
30 | |
31 enum | |
32 { | |
33 kCFNumberSInt8Type = 1, | |
34 kCFNumberSInt16Type = 2, | |
35 kCFNumberSInt32Type = 3, | |
36 kCFNumberSInt64Type = 4, | |
37 kCFNumberFloat32Type = 5, | |
38 kCFNumberFloat64Type = 6, | |
39 kCFNumberCharType = 7, | |
40 kCFNumberShortType = 8, | |
41 kCFNumberIntType = 9, | |
42 kCFNumberLongType = 10, | |
43 kCFNumberLongLongType = 11, | |
44 kCFNumberFloatType = 12, | |
45 kCFNumberDoubleType = 13, | |
46 kCFNumberCFIndexType = 14, | |
47 kCFNumberNSIntegerType = 15, | |
48 kCFNumberCGFloatType = 16, | |
49 kCFNumberMaxType = 16 | |
50 } | |
51 | |
52 extern (C) | |
53 { | |
54 uint CFBooleanGetTypeID (); | |
55 ubyte CFBooleanGetValue (CFBooleanRef boolean); | |
56 uint CFNumberGetTypeID (); | |
57 CFNumberRef CFNumberCreate (CFAllocatorRef allocator, int theType, void* valuePtr); | |
58 int CFNumberGetType (CFNumberRef number); | |
59 int CFNumberGetByteSize (CFNumberRef number); | |
60 ubyte CFNumberIsFloatType (CFNumberRef number); | |
61 ubyte CFNumberGetValue (CFNumberRef number, int theType, void* valuePtr); | |
62 int CFNumberCompare (CFNumberRef number, CFNumberRef otherNumber, void* context); | |
63 } |