Buffers Galore! Now in Version 1.2

Dequesterity is a set of Ada 2005 generics that provide various forms of general purpose buffer containers. There are currently 75 (yes, seventy-five) buffer types in Dequesterity, so if you’re in the market for a buffer, chances are high that you’ll find what you need here.

Dequesterity is a set of Ada 2005 generics that provide various forms of general purpose buffer containers. Buffers may be used as deques, queues, ring buffers, stacks, double ended stacks, vectors, and similar abstractions.

The generics are combinable and pluggable such that lower level buffer implementations may be combined with higher level buffer generics to create a wide selection of buffer types with specific sets of functionality.

Lower level buffer implementations include bounded and unbounded buffer forms. Higher level buffer implementations add concurrency support, and streaming capabilities. Buffer instances may be streamed, or may be accessed remotely using the Distributed Systems Annex. Most buffers can store their state persistently. Some buffer implementations operate entirely on secondary (file based) storage. The buffers may be instantiated with user defined types, and indefinite buffer forms also exist.

The interface to the buffers is modelled after the Ada 2005 container library.

New in release 1.2 is:

  • Saving/Loading buffers from files, and Persistent Buffers were not working under Linux. The low level Preelaborated IO had some portability issues in the area of determining the size of a file. The Linux test executable, test_buffers now works as it should.
  • Prelaborated_IO Size now returns a long integer instead of Integer. (Which would be 64 bits on 64 bit OS’s) This allows buffers to work with much larger files, if buffer content is to be stored persistently.
  • Only one project file needed for an executable, that builds for both Windows and Linux.
  • Cleaned up compiler warnings.
  • Created a Buffer Demo executable, which is stripped down to demonstrate some buffer concepts.
  • Ravenscar example exits after 30 seconds, instead of executing indefinitely.
  • Persistent Stream Buffers do not need to be instantiated, similar to the other Stream Buffer types.
  • Fixed bug in Unbounded Buffer, if vector to read into is a zero element array, the Read routine does not generate a constraint error.
  • Fixed bug in indefinite Unbounded buffers. When finalizing the buffer if the internal buffer is null, don’t attempt to dereference the null value.

You can read the full release announcement from Brad Moore here.

Leave a Reply