GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | ||||||||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | ||||||||||||
GeezerVison is showing dlib.net — dlib C++ Library - Parsing The Library
Help/Info
Current Release Download dlib ver.20.0
Last Modified: Sep 17, 2023 Parsing This page documents the objects and functions that in some way deal with parsing or otherwise manipulating text. Everything here follows the same conventions as the rest of the library. Objects
Global Functions
base64This object allows you to encode and decode data to and from the Base64 Content-Transfer-Encoding defined in section 6.8 of rfc2045. C++ Example Programs: file_to_code_ex.cpp More Details... #include <dlib/base64.h> basic_utf8_ifstreamThis object represents an input file stream much like the normal std::ifstream except that it knows how to read UTF-8 data. So when you read characters out of this stream it will automatically convert them from the UTF-8 multibyte encoding into a fixed width wide character encoding. There are also two typedefs of this object. The first is utf8_wifstream which is a typedef for wchar_t as the wide character to read into. The second is utf8_uifstream which uses unichar instead of wchar_t. More Details... #include <dlib/unicode.h> cast_to_stringcast_to_string is a templated function which makes it easy to convert arbitrary objects to std::string strings. The types supported are any types that can be written to std::ostream via operator<<. More Details... #include <dlib/string.h> cast_to_wstringcast_to_string is a templated function which makes it easy to convert arbitrary objects to std::wstring strings. The types supported are any types that can be written to std::wostream via operator<<. More Details... #include <dlib/string.h> cmd_line_parserThis object allows you to easily parse a command line. Note that the documentation for the cmd_line_parser_option (the object returned by the parser's .option() function) is in a separate file. Note also that there are standard typedefs for the ASCII and wide character versions of the cmd_line_parser template. These are the command_line_parser and wcommand_line_parser types respectively. C++ Example Programs: compress_stream_ex.cpp, train_object_detector.cpp More Details... #include <dlib/cmd_line_parser.h> Extensions to cmd_line_parserget_option This extension provides a convenience function for accessing the options to a command line argument or a config_reader. It is automatically #included when using the command line parser or config reader. More Details... config_readerThis object represents something which is intended to be used to read text configuration files. C++ Example Programs: config_reader_ex.cpp More Details... #include <dlib/config_reader.h> Extensions to config_readerconfig_reader_thread_safe This object extends a normal config_reader by simply wrapping all its member functions inside mutex locks to make it safe to use in a threaded program. More Details... convert_to_utf32This is a global function that can convert UTF-8, UTF-16, UTF-32, or ASCII strings into strings of 32bit unichar characters. That is, it takes any kind of UTF string and returns the UTF-32 representation of that string. More Details... #include <dlib/unicode.h> cpp_pretty_printerThis object represents an HTML pretty printer for C++ source code. More Details... #include <dlib/cpp_pretty_printer.h> Implementations: cpp_pretty_printer_kernel_1: cpp_pretty_printer_kernel_2: cpp_tokenizerThis object represents a simple tokenizer for C++ source code. More Details... #include <dlib/cpp_tokenizer.h> Implementations: cpp_tokenizer_kernel_1: is_combining_charThis is a global function that can tell you if a character is a Unicode combining character or not. More Details... #include <dlib/unicode.h> left_substrThis is a function to return the part of a string to the left of a user supplied delimiter. More Details... #include <dlib/string.h> lpadThis is a function to pad whitespace (or user specified characters) onto the left most end of a string. More Details... #include <dlib/string.h> ltrimThis is a function to remove the whitespace (or user specified characters) from the left most end of a string. More Details... #include <dlib/string.h> narrowThis is a function for converting a string of type std::string or std::wstring to a plain std::string. More Details... #include <dlib/string.h> padThis is a function to pad whitespace (or user specified characters) onto the ends of a string. More Details... #include <dlib/string.h> pad_int_with_zerosConverts an integer into a string and pads it with leading zeros. More Details... #include <dlib/string.h> right_substrThis is a function to return the part of a string to the right of a user supplied delimiter. More Details... #include <dlib/string.h> rpadThis is a function to pad whitespace (or user specified characters) onto the right most end of a string. More Details... #include <dlib/string.h> rtrimThis is a function to remove the whitespace (or user specified characters) from the right most end of a string. More Details... #include <dlib/string.h> splitBreaks a string into a sequence of substrings delimited by a user specified set of characters. More Details... #include <dlib/string.h> split_on_firstBreaks a string into two parts. The split point is selected based on the first occurrence of a delimiter character. More Details... #include <dlib/string.h> split_on_lastBreaks a string into two parts. The split point is selected based on the last occurrence of a delimiter character. More Details... #include <dlib/string.h> strings_equal_ignore_caseThis is a pair of functions to do a case insensitive comparison between strings. More Details... #include <dlib/string.h> string_assignstring_assign is an object which makes it easy to convert strings to other types. The types supported are any types that can be read by the basic_istream operator>>. It also supports casting between wstring, string, and ustring objects. Since string_assign is a simple stateless object there is a global instance of it called dlib::sa. C++ Example Programs: config_reader_ex.cpp More Details... #include <dlib/string.h> string_caststring_cast is a templated function which makes it easy to convert strings to other types. The types supported are any types that can be read by the basic_istream operator>>. It also supports casting between wstring, string, and ustring objects. More Details... #include <dlib/string.h> tokenizerThis object represents a simple tokenizer for textual data. More Details... #include <dlib/tokenizer.h> Implementations: tokenizer_kernel_1: tolowerThis is a function to convert a string to all lowercase. More Details... #include <dlib/string.h> toupperThis is a function to convert a string to all uppercase. More Details... #include <dlib/string.h> trimThis is a function to remove the whitespace (or user specified characters) from the ends of a string. More Details... #include <dlib/string.h> unicharThis is a typedef for an unsigned 32bit integer which we use to store Unicode values. More Details... #include <dlib/unicode.h> ustringThis is a typedef for a std::basic_string<unichar>. That is, it is a typedef for a string object that stores unichar Unicode characters. More Details... #include <dlib/unicode.h> wrap_stringwrap_string is a function that takes a string and breaks it into a number of lines of a given length. You can use this to make a string fit nicely into a command prompt window for example. More Details... #include <dlib/string.h> xml_parserThis object represents a simple SAX style event driven XML parser. It takes its input from an input stream object and sends events to all registered document_handler and error_handler objects. The xml_parser object also uses the interface classes document_handler and error_handler. Subclasses of these classes are passed to the xml_parser which generates events while it's parsing and sends them to the appropriate handler. C++ Example Programs: xml_parser_ex.cpp More Details... #include <dlib/xml_parser.h> | ||||||||||||
| You are visitor 01402503 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |