The Script Plus Plus library homepage

The Script Plus Plus library (a.k.a. ScriptPP) is a collection of C++ classes to do the things you usually do in so-called scripting languages such as Perl, Tcl, Bash etc. The main class is named ScriptVariable and it seems to be a good replacement for the standard string class. Why to replace it? At least because it doesn't provide no operations of tokenization, breaking a string down to words, and conversion to integers and floats - the things which I need tens of times more often that, heh, replacing a region etc... ScriptVariable does all these things, and, BTW, it also allows to replace and/or erase substrings if you want, but it does that with more object-oriented style (a range is a slave object, and it has Erase and Replace methods). Needless to say that concatenation with operator+ and operator+= is also available ;-)

The library also includes the ScriptVector class which implements a dynamically resized vector of strings; this is what you get when you break your string down to words or tokens.

Besides that, there are sets of strings (the ScriptSet class) and maps of string to string (the ScriptMap class), implemented as hash tables.

Strings are not only objects handled by the library. It includes the cmd module which provides facilities to read (and analyse) streams, execute external programs and to restore your terminal mode in case the external program spoils it.

No other libraries are needed to use ScriptPP. Nothing but the C standard library is used by the code (these strcmp, strcpy etc). No STL, and certainly no string class. Heh, personally I just hate STL. C++ is nice. STL is a bad monster.

The library is available under the terms and conditions of GNU Lesser General Public License, v. 2.1.

The last version is 0.3.00 and it is available for downloading in the form of source tarball here via ftp and here via http.

This is a pre-beta version. Please don't expect too much. I'm really sorry that, as for now, I've got no documentation for the library. I hope to add it later, and for now just take a look at the header files.

C++ libraries at Croco.Net

Valid HTML 3.2!

The page changed November 06, 2009