public abstract class FunctionPointer extends Pointer
Generator create a native function type.
A C++ function object gets instantiated for each call to allocate()
as well. That function object can be accessed by annotating any method
parameter with ByVal or ByRef. By default, an actual
function pointer gets passed ByPtr.
To use FunctionPointer, subclass and add a native method named call()
or apply(), along with its return type and parameters, as well as the
usual native void allocate() method to support explicit allocation,
which is typically a requirement for callback functions.
GeneratorPointer.CustomDeallocator, Pointer.Deallocator, Pointer.DeallocatorReference, Pointer.DeallocatorThread, Pointer.NativeDeallocatoraddress, capacity, deallocatorThread, limit, maxBytes, maxPhysicalBytes, maxRetries, position| Modifier | Constructor and Description |
|---|---|
protected |
FunctionPointer() |
protected |
FunctionPointer(Pointer p) |
address, asBuffer, asByteBuffer, availablePhysicalBytes, calloc, capacity, capacity, close, deallocate, deallocate, deallocateReferences, deallocator, deallocator, equals, fill, formatBytes, free, hashCode, init, isNull, limit, limit, malloc, maxBytes, maxPhysicalBytes, memchr, memcmp, memcpy, memmove, memset, offsetof, parseBytes, physicalBytes, position, position, put, realloc, setNull, sizeof, toString, totalBytes, totalPhysicalBytes, withDeallocator, zeroprotected FunctionPointer()
protected FunctionPointer(Pointer p)
Copyright © 2017. All rights reserved.