module Bindings.APR.Allocator where
#strict_import
import Bindings.APR
+import Bindings.APR.Allocator.Types
import Bindings.APR.Errno
-
-#opaque_t apr_allocator_t
-
-#starttype struct apr_memnode_t
-#field next , Ptr <apr_memnode_t>
-#field ref , Ptr (Ptr <apr_memnode_t>)
-#field index , <apr_uint32_t>
-#field free_index , <apr_uint32_t>
-#field first_avail, Ptr CChar
-#field endp , Ptr CChar
-#stoptype
+import Bindings.APR.Pools
#num APR_MEMNODE_T_SIZE
#num APR_ALLOCATOR_MAX_FREE_UNLIMITED
#ccall apr_allocator_alloc , Ptr <apr_allocator_t> -> <apr_size_t> -> IO (Ptr <apr_memnode_t>)
#ccall apr_allocator_free , Ptr <apr_allocator_t> -> Ptr <apr_memnode_t> -> IO ()
--- FIXME: incomplete
+#ccall apr_allocator_owner_set, Ptr <apr_allocator_t> -> Ptr <apr_pool_t> -> IO ()
+#ccall apr_allocator_owner_get, Ptr <apr_allocator_t> -> IO (Ptr <apr_pool_t>)
+
+#ccall apr_allocator_max_free_set, Ptr <apr_allocator_t> -> <apr_size_t> -> IO ()
+
+-- FIXME: incomplete
\ No newline at end of file