Skip Headers

Oracle® XML API Reference
10g Release 1 (10.1)

Part Number B10789-01
Go to Documentation Home
Home
Go to Book List
Book List
Go to Table of Contents
Contents
Go to Master Index
Master Index
Go to Feedback page
Feedback

Go to previous page
Previous
Go to next page
Next
View PDF

MemAllocator Interface

Table 14-2 summarizes the methods of available through the MemAllocator interface.

Table 14-2 Summary of MemAllocator Methods; Ctx Package

Function Summary
alloc
Allocates memory of given size.
dealloc
Deallocate memory pointed to by the argument.
~MemAllocator
Virtual destructor - interface level handle to actual destructors.


alloc

This is a virtual member function that defines a prototype for user defined allocator functions


Syntax
virtual void* alloc(
   ub4 size) = 0;

Parameter Description
size
memory size


dealloc

This is a virtual member function that defines a prototype for user defined deallocator functions. Such deallocators are supposed to deallocate memory allocated by the alloc member functions


Syntax
virtual void dealloc(
   void* ptr) = 0;

Parameter Description
ptr
pointer to previously allocated memory


~MemAllocator

It provides an interface level handle to actual destructors that can be invoked without knowing their names or implementations


Syntax
virtual ~MemAllocator() {}