dart:ffi library

Classes

DartRepresentationOf
Double
Represents a native 64 bit double in C. [...]
DynamicLibrary
Represents a dynamically loaded C library.
Float
Represents a native 32 bit float in C. [...]
Int8
Represents a native signed 8 bit integer in C. [...]
Int16
Represents a native signed 16 bit integer in C. [...]
Int32
Represents a native signed 32 bit integer in C. [...]
Int64
Represents a native signed 64 bit integer in C. [...]
IntPtr
Represents a native pointer-sized integer in C. [...]
NativeFunction<T extends Function>
Represents a function type in C. [...]
NativeType
NativeType's subtypes represent a native type in C. [...]
Pointer<T extends NativeType>
Represents a pointer into the native C memory.
Struct
Uint8
Represents a native unsigned 8 bit integer in C. [...]
Uint16
Represents a native unsigned 16 bit integer in C. [...]
Uint32
Represents a native unsigned 32 bit integer in C. [...]
Uint64
Represents a native unsigned 64 bit integer in C. [...]
Unsized
Void
Represents a void type in C. [...]

Constants

struct → const Struct
This Dart class represents a C struct. [...]
const Struct()
unsized → const Unsized
This NativeType does not have predefined size. [...]
const Unsized()

Functions

allocate<T extends NativeType>({int count: 1 }) Pointer<T>
Allocate count elements of type T on the C heap with malloc() and return a pointer to the newly allocated memory. [...]
fromAddress<T extends Pointer<NativeType>>(int ptr) → T
Construction from raw value
fromFunction<T extends Function>(Function f) Pointer<NativeFunction<T>>
Convert Dart function to a C function pointer, automatically marshalling the arguments and return value [...]
sizeOf<T extends NativeType>() int
number of bytes used by native type T