Added API for allocating buffer objects.
Factory for instances of buffer allocators.

This indirection is designed for users for the library to be able to
plug in their own implementation of an allocator using standard Java
SPI mechanisms.