protected static class Pointer.CustomDeallocator extends Pointer.DeallocatorReference
Pointer.Deallocator that calls, during garbage collection, a method with signature
static void deallocate() from the Pointer object passed to the constructor
and that accepts it as argument. Uses reflection to locate and call the method.Pointer.withDeallocator(Pointer)| Modifier and Type | Field and Description |
|---|---|
(package private) Method |
method |
(package private) Pointer |
pointer |
bytes, count, deallocator, head, next, prev, totalBytes, totalCount| Constructor and Description |
|---|
CustomDeallocator(Pointer p) |
| Modifier and Type | Method and Description |
|---|---|
void |
deallocate() |
String |
toString() |
add, clear, count, release, remove, retaingetclone, enqueue, isEnqueuedpublic CustomDeallocator(Pointer p)
public void deallocate()
deallocate in interface Pointer.Deallocatordeallocate in class Pointer.DeallocatorReferencepublic String toString()
toString in class Pointer.DeallocatorReferenceCopyright © 2025. All rights reserved.