blob: a6649a79d9a7e8ac91c6723558cc876d06b68374 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
|
<?php
/** @generate-class-entries */
namespace {
final class FFI
{
public static function cdef(string $code = "", ?string $lib = null): FFI {}
public static function load(string $filename): ?FFI {}
public static function scope(string $name): FFI {}
public static function new(FFI\CType|string $type, bool $owned = true, bool $persistent = false): ?FFI\CData {}
/** @prefer-ref $ptr */
public static function free(FFI\CData $ptr): void {}
/**
* @param FFI\CData|int|float|bool|null $ptr
* @prefer-ref $ptr
*/
public static function cast(FFI\CType|string $type, $ptr): ?FFI\CData {}
public static function type(string $type): ?FFI\CType {}
/** @prefer-ref $ptr */
public static function typeof(FFI\CData $ptr): FFI\CType {}
public static function arrayType(FFI\CType $type, array $dimensions): FFI\CType {}
/** @prefer-ref $ptr */
public static function addr(FFI\CData $ptr): FFI\CData {}
/** @prefer-ref $ptr */
public static function sizeof(FFI\CData|FFI\CType $ptr): int {}
/** @prefer-ref $ptr */
public static function alignof(FFI\CData|FFI\CType $ptr): int {}
/**
* @param FFI\CData|string $from
* @prefer-ref $to
* @prefer-ref $from
*/
public static function memcpy(FFI\CData $to, $from, int $size): void {}
/**
* @prefer-ref $ptr1
* @param string|FFI\CData $ptr1
* @prefer-ref $ptr2
* @param string|FFI\CData $ptr2
*/
public static function memcmp($ptr1, $ptr2, int $size): int {}
/** @prefer-ref $ptr */
public static function memset(FFI\CData $ptr, int $value, int $size): void {}
/** @prefer-ref $ptr */
public static function string(FFI\CData $ptr, ?int $size = null): string {}
/** @prefer-ref $ptr */
public static function isNull(FFI\CData $ptr): bool {}
}
}
namespace FFI {
final class CData {
}
final class CType {
public function getName() : string {}
}
class Exception extends \Error {
}
final class ParserException extends Exception {
}
}
|