FBB::OHexStreambuf(3bobcat)
Write hex values
(libbobcat-dev_4.09.00-x.tar.gz)
2005-2019
NAME
FBB::OHexStreambuf - Writes characters written to an ostream as hex
values
SYNOPSIS
#include <bobcat/ohexstreambuf>
Linking option: -lbobcat
DESCRIPTION
OHexStreambuf is a specialization of FBB::OFilterStreambuf
inserting all the characters it receives to a destination file as 2-character
wide hexadecimal values. Optionally a maximum linelength can be specified.
Note that all information received by an OHexStreambuf object is inserted
as (a series of) hexadecimal values, not only plain characters. E.g., when
inserting the value 123 the characters '1', '2' and '3' are
successively inserted and so this will result in the string 313233 being
inserted into the destination stream.
NAMESPACE
FBB
All constructors, members, operators and manipulators, mentioned in this
man-page, are defined in the namespace FBB.
INHERITS FROM
FBB::OFilterStreambuf
CONSTRUCTOR
- OFoldStreambuf(std::ostream &stream, size_t width = 0):
The hexadecimal characters produced by the OFoldStreambuf object will
be inserted into stream. Optionally the maximum line width (in number of
characters) may be specified using width. The (default) value 0 indicates
that no line breaks are requested.
The destructor writes any buffered information to the destination stream
and will then flushes the destination stream.
MEMBER FUNCTIONS
All members of FBB::OFilterStreambuf, in particular its out() and
open() members are available, as FBB::OHexStreambuf inherits from
this class.
STATIC MEMBER
EXAMPLE
#include <iostream>
#include <bobcat/ohexstreambuf>
using namespace std;
using namespace FBB;
int main()
{
OHexStreambuf ohex(cout, 40);
ostream out(&ohex);
out << cin.rdbuf();
if (ohex.size())
cout << '\n';
}
FILES
bobcat/ohexstreambuf - defines the class interface
SEE ALSO
bobcat(7), ofilterstreambuf(3bobcat)
BUGS
None Reported.
DISTRIBUTION FILES
- bobcat_4.09.00-x.dsc: detached signature;
- bobcat_4.09.00-x.tar.gz: source archive;
- bobcat_4.09.00-x_i386.changes: change log;
- libbobcat1_4.09.00-x_*.deb: debian package holding the
libraries;
- libbobcat1-dev_4.09.00-x_*.deb: debian package holding the
libraries, headers and manual pages;
- http://sourceforge.net/projects/bobcat: public archive location;
BOBCAT
Bobcat is an acronym of `Brokken's Own Base Classes And Templates'.
COPYRIGHT
This is free software, distributed under the terms of the
GNU General Public License (GPL).
AUTHOR
Frank B. Brokken (f.b.brokken@rug.nl).