Simple Utility Classes


Introduction

There are many great open source utility libraries out there. Most of them are written using C. This is probably because C is a very widely used and well known language and is known to be very portable. Unfortunately for Standardised C++ coders, these C libraries and APIs represent a problem. Good C++ code can be turned very bad by problematic use of C libraries. The STL, while it is very good at being backwards compatible to much of C's pragmatism isn't 100% compatible and can be very cumbersome to translate between the two (arrays <=> vectors, char * <=> string, stdio <=> iostream).

I created the SUCs out of pragmatism as much as anything since I found myself wanting the same classes for different projects. So far they are by no means complete though I myself found them to be very useful.

It is important to note that they are not just C++ wrappers for C libraries - they are created with the intention of not only transfering functionality but also, where possible, adding simplicity and OO/STL idealism and methodology.

The thread library for instance not only encapsulates the pthread stuff but also adds extra, commmonly needed features for stoping and killing threads easily and simply. The daemon library could have been implemented almost exactly the same in C, and thus is not really a wrapper - it simply and effectively makes daemonising easy.

The libraries are meant to be (as far as they can be) platform independant (though obviously if the functionality is impossible to acheive they won't be implemented). So far I have developed on Unix primarily, however I would be happy for anyone to help in porting them to other platforms.

Overview

So far 6 libraries have been completed:

A further network library is on the way.

Licence

The licence used for distribution is the GNU Lesser General Public Licence. This means if you change the code or use it in another project the project or changes must also be placed under this licence. However there are no such restrictions on code that is simply dynamicly linked to it at run-time.

This software comes without a warranty of any kind. USE AT YOUR OWN RISK.

Links

Contact

You can contact me, Gav Wood, at gav.a.kde...org.