randolf.ca  1.00
Randolf Richardson's C++ classes
Loading...
Searching...
No Matches
Randolf Richardson's C++ classes

The intention of these C++ classes is to simplify programming some particularly tedious aspects of the C programming APIs that are also commonly relied on in a lot of C++ applications and projects ... including, in particular, the error codes that are normally returned by many POSIX, OpenSSL, and other functions in a purely procedural fashion, for which I wrote a set of exceptions classes – the randolf::rex::rex class can be used independently for applications and projects that don't rely on any of my other projects/classes (that are included in this documentation).

Efforts are also made to ensure that developers have access to underlying handles, such as socket handles, library contexts, etc., so that developers aren't limited to whatever the class can provide. There are some caveats with doing this though, but the relevant warnings are documented accordingly (e.g., I/O tracking doesn't occur when using socket handles directly).

My C++ code compiles properly with the following compiler options (which is somewhat similar to using the strict and warnings modules in Perl):

-Wall -Wextra -Wshadow -pedantic

This means that if you have high coding standards that utilize any or all of these compiler options, that my code won't introduce any additional warnings or errors. (If there is a compiler setting that doesn't work perfectly, and it's something that I can utilize as an opportunity to further improve my code, I would love to know about it.)

List of classes for which the documentation is presently available:

  • randolf::Atomize (split atoms safely by making a line or block of accessible in an array-like fashion, with additional conveniences for any key-value pairs that were detected)
  • randolf::rex::rex (main exceptions class, with subclasses for handling over 100 error codes {including TLS errors from OpenSSL})
  • randolf::rhostname (hostname class that supports internationalized internet domain names and provides a variety of helpful convenience methods for accessing/changing labels, checking compliance with various internet hostname standards, etc.)
    • randolf::rlabel (label structure used by the hostname class for each dot-delimited portion of the hostname, with a variety of flags that are useful for understanding independently what each label that an rhostname object is comprised of represents)
  • randolf::rline (container for a one-line string, plus a field for the EoF sequence which also indicates whether there was an EoF sequence)
  • randolf::rmailaddr (eMail address class that provides a variety of specialized helpful parsing methods, syntax/validity checking, etc.)
  • randolf::rring (ring buffer that's both resizable and threadsafe)
  • randolf::rsocket (socket class with recvline/sendline, TLS, SNI, muxxing, endianness transparency, etc., support)
    • randolf::rsocket_group (class for performing mass operations on multiple rsocket objects)
    • randolf::rsocket_group_rc (structure that holds rsocket counts of bytes successfully transmitted, or exceptions that were thrown)
    • randolf::rsocket_io (structure that holds an rsocket's I/O statistics)
    • randolf::rsocket_mux (class for multiplexing operations on multiple rsocket objects, such as the select() and poll() functions)
    • randolf::rsocket_mux_fds (structure that holds rsocket pointers/handles)
    • randolf::rsocket_sni (class that is used to implement support for multiple TLS certificates with SNI, which is the Server Name Identifier extension that is supported with OpenSSL callbacks)
  • randolf::rthread (sublcassable POSIX threads, with programmable post-thread exception intervention, and a destructor that's called only after the thread has ended)
  • randolf::rtools (various static methods that provide useful functionality)

Class naming notes:

The names of "core" classes are prefixed with a letter "r" which also serves the purpose to differentiate them from generically-named classes or well-known enough classes so as to avoid naming conflicts.

Various other classes without names that conflict with well-known alternatives might not begin with a letter "r" (or "R") and could also possess a mixed-case naming style.

Classes planned for future projects:

  • randolf::gui::ProgressBar (a 2D progress bar with a partly-3D appearance that represents a finer granularity)
  • randolf::gui::RScreen (text-mode screen for use in various GUI/graphics projects)

The documentation for these classes is available on my web site:

‍ Randolf Richardson's software development web site
https://www.randolf.ca/c++

A tremendous amount of time and effort went into the planning, development, and testing of these C++ classes, which are available for free (meaning that you are not obligated to pay for any usage or licensing fees). However, if you'd like to support me financially for my efforts, this will be helpful to me and I'd greatly appreciate it. For more information, please visit my web site for the most recent contact information and support options. Thank you.

If you're using any of my software in any of your software projects, please let me know so that I may include a reference to your works on my web site so that others can find them. I want to include your software in my list regardless of whether it's free, shareware, commercial, or something else.