|
Boost : |
Subject: [boost] Heterogeneous Container Library (HCL) Feedback and Testing
From: James Armstrong (armstrhu_at_[hidden])
Date: 2015-06-02 17:41:04
I send out a little feeler about a month ago for interest in a container
library which natively allows users to insert a heterogeneous set of
types. After getting some really good feedback, I think I have settled
into something that is efficient, has a nice clean interface, and provides
some useful capabilities. I am hoping people can take a look at the code,
test it out, and provide an additional feedback in terms of interface,
implementation, bugs, or additional features/classes that would be useful.
I have implemented a set of containers which mimic the capabilities of the
STL containers. These are (so far)
* heterovector
* heterostack
* heteroqueue
* heterolist
* heteroforward_list
* heterodeque
These containers were implemented using variadic templates and were
somewhat inspired from the posts of JoaquÃn Muñoz.
http://bannalia.blogspot.com/2014/05/fast-polymorphic-collections.html
http://bannalia.blogspot.com/2014/05/fast-polymorphic-collections-with.html
In addition, I have an adaptor class which provides a simple interface for
accessing data of a specific type from a container of type_erased objects
(boost::any, boost::variant, etc).
The code is hosted at
https://github.com/armstrhu/HCL
and the directory structure there should be simple to navigate. There is
an include directory which contains the header files needed, and an
examples directory which provides examples for using the containers and the
adaptors. As they mimic the STL containers, once you see how to use them
(basically just provide an additional template parameter) you should be
able to use them smoothly.
One note is I focused mainly on developing the heterovector class, and the
remainders are primarily copies of that class where std::vector has been
replaced with std::deque, std::list, etc, and associated methods
added/removed as needed. I have primarily tested with the heterovector, so
having people check out the other classes would be nice :)
Any and all feedback is much appreciated. Thanks!
-- James Armstrong
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk