ximol/parser/utils.hpp File Reference


Detailed Description

All parser functions declarations.

Author:
Tournois Florent
Version:
1.0
Id
utils.hpp,v 1.10 2004/02/22 10:27:34 tournois Exp
Log
utils.hpp,v
Revision 1.10 2004/02/22 10:27:34 tournois Add some doc.

Revision 1.9 2004/02/22 09:54:20 tournois Change years on the copyright.

Revision 1.8 2004/01/09 18:26:29 tournois Add box and content manipulator.

Revision 1.7 2003/11/27 15:31:55 hfp partially adapted to vc6.

Revision 1.6 2003/11/16 13:25:25 tournois Change the error to use wide string. Change the translation to use wide string.

Revision 1.5 2003/11/02 19:23:01 tournois Go to the boost coding standard. Change all name to lower case.

Revision 1.4 2003/10/25 13:53:40 hfp review and separation

Revision 1.3 2003/10/08 19:59:35 tournois no message

Revision 1.2 2003/09/27 22:49:34 tournois add the UTF-7 BOM. UTF-7 files can have a BOM too: 2B 2F 76 38 2D (ASCII +/v8-).

Revision 1.1 2003/09/24 08:28:17 tournois Create the namespace Encoders, Parser, Xml Change the library organization. add VC7.1 project for this organization.

Definition in file utils.hpp.

#include <ximol/typedefs.hpp>
#include <ximol/export_defs.hpp>

Include dependency graph for utils.hpp:

Include dependency graph

This graph shows which files directly or indirectly include this file:

Included by dependency graph

Go to the source code of this file.

Functions

XIMOL_XML_END_NAMESPACE XIMOL_PARSER_BEGIN_NAMESPACE
XIMOL_EXPORT void 
write_xchar (xostream &xos, xchar_t xc)
 Put a char in the stream Do not use this function.

XIMOL_EXPORT xistreamread_xchar (xistream &xis, xchar_t xc, const::std::wstring &error_msg=L"")
 read Special char.

XIMOL_EXPORT xistreamread_xchar (xistream &xis, xchar_t &xc, bool(*is_good_xchar)(xchar_t), const::std::wstring &error_msg=L"")
 read Char defined by a function.

XIMOL_EXPORT xistreamread_xstring (xistream &xis, xstring &xstr, bool(*is_good_xchar)(xchar_t), bool erase_string=true)
 read string defined by a function.

XIMOL_EXPORT bool is_xstring (const xstring &xstr, bool(*is_good_xchar)(xchar_t))
 Test string defined by a function.

XIMOL_EXPORT xistreamread_xstring (xistream &xistream_, const::std::string &str_, const::std::wstring &strErrorMsg_=L"", size_t size_=0)
 read Special string.

XIMOL_EXPORT xostreamwrite_string_with_forbidden_serie (xostream &xos, const xstring &xstr, bool(*is_good_xchar)(xchar_t), const::std::string &forbidden_string, const::std::string &entity_test, const::std::string &entity_definition)
XIMOL_EXPORT xistreamread_string_with_forbidden_serie (xistream &xis, xstring &xstr, bool(*is_good_xchar)(xchar_t), const::std::string &forbidden_string)
XIMOL_EXPORT bool is_string_with_forbidden_serie (const xstring &xstr, bool(*is_good_xchar)(xchar_t), const::std::string &forbidden_string)
XIMOL_EXPORT bool is_in_range (xchar_t c, xchar_t lower, xchar_t upper)
XIMOL_EXPORT bool is_space (xchar_t c)
XIMOL_EXPORT bool is_digit (xchar_t c)
XIMOL_EXPORT bool is_char (xchar_t c)
XIMOL_EXPORT bool is_letter (xchar_t c)
XIMOL_EXPORT bool is_combining_char (xchar_t c)
XIMOL_EXPORT bool is_base_char (xchar_t c)
XIMOL_EXPORT bool is_ideographic (xchar_t c)
XIMOL_EXPORT bool is_extender (xchar_t c)
XIMOL_EXPORT bool is_name_char (xchar_t c)
XIMOL_EXPORT bool is_pubid_char (xchar_t c)
XIMOL_EXPORT xostreamwrite_space (xostream &xos)
XIMOL_EXPORT xistreamread_space (xistream &xis)
XIMOL_EXPORT xistreamread_optionnal_space (xistream &xis)
XIMOL_EXPORT xostreamwrite_name (xostream &xos, const xstring &xstr)
XIMOL_EXPORT xistreamread_name (xistream &xis, xstring &xstr)
XIMOL_EXPORT bool is_name (const xstring &xstr)
XIMOL_EXPORT xostreamwrite_ncname (xostream &xos, const xstring &xstr)
XIMOL_EXPORT xistreamread_ncname (xistream &xis, xstring &xstr)
XIMOL_EXPORT bool is_ncname (const xstring &xstr)
XIMOL_EXPORT bool is_qname (const xstring &localPart, const xstring &prefix=xstring())
XIMOL_EXPORT bool is_first_char_name (xchar_t xc)
XIMOL_EXPORT bool is_first_char_ncname (xchar_t xc)
XIMOL_EXPORT xostreamwrite_char_data (xostream &xos, const xstring &xstr)
XIMOL_EXPORT xistreamread_char_data (xistream &xis, xstring &xstr)
XIMOL_EXPORT bool is_char_data (const xstring &xstr)
XIMOL_EXPORT xostreamwrite_nm_token (xostream &xos, const xstring &xstr)
XIMOL_EXPORT xistreamread_nm_token (xistream &xis, xstring &xstr)
XIMOL_EXPORT bool is_nm_token (const xstring &xstr)
XIMOL_EXPORT xostreamwrite_char_ref (xostream &xos, xchar_t xc)
XIMOL_EXPORT xistreamread_char_ref (xistream &xis, xchar_t &xc, int nb_read=0)
XIMOL_EXPORT xostreamwrite_entity_ref (xostream &xos, const xstring &xstr)
XIMOL_EXPORT xistreamread_entity_ref (xistream &xis, int nb_read=0)
XIMOL_EXPORT xostreamwrite_pe_reference (xostream &xos, const xstring &xstr)
XIMOL_EXPORT xistreamread_pe_reference (xistream &xis, xstring &xstr, int nb_read=0)
XIMOL_EXPORT xistreamread_reference (xistream &xis, xstring &xstr, int nb_read=0)
XIMOL_EXPORT xostreamwrite_pubid_literal (xostream &xos, const xstring &xstr)
XIMOL_EXPORT xistreamread_pubid_literal (xistream &xis, xstring &xstr)
XIMOL_EXPORT xostreamwrite_system_literal (xostream &xos, const xstring &xstr, xchar_t quote=0x0022)
XIMOL_EXPORT xistreamread_system_literal (xistream &xis, xstring &xstr)
XIMOL_EXPORT xostreamwrite_entity_value (xostream &xos, const xstring &xstr, xchar_t quote=0x0022)
XIMOL_EXPORT xistreamread_entity_value (xistream &xis, xstring &xstr)
XIMOL_EXPORT xostreamwrite_att_value (xostream &xos, const xstring &xstr, xchar_t quote=0x0022)
XIMOL_EXPORT xistreamread_att_value (xistream &xis, xstring &xstr)
XIMOL_EXPORT xostreamwrite_attribute (xostream &xos, const xstring &name, const xstring &att_value, const xstring &short_ns, xchar_t quote=0x0022)
XIMOL_EXPORT xistreamread_attribute (xistream &xis, xstring &name, xstring &att_value, xstring &short_ns)
XIMOL_EXPORT bool is_comment (const xstring &xstr)
XIMOL_EXPORT xostreamwrite_comment (xostream &xos, const xstring &xstr)
XIMOL_EXPORT xistreamread_comment (xistream &xis, xstring &xstr, int nb_read=0)
XIMOL_EXPORT xistreamread_comment (xistream &xis, int nb_read=0)
XIMOL_EXPORT bool is_pi_target (const xstring &xstr)
XIMOL_EXPORT xostreamwrite_pi_target (xostream &xos, const xstring &xstr)
XIMOL_EXPORT xistreamread_pi_target (xistream &xis, xstring &xstr)
XIMOL_EXPORT xostreamwrite_pi (xostream &xos, const xstring &pi_target, const xstring &xext)
XIMOL_EXPORT xistreamread_pi (xistream &xis, xstring &pi_target, xstring &xext, int nb_read=0)
XIMOL_EXPORT xistreamread_pi (xistream &xis, int nb_read=0)
XIMOL_EXPORT xostreamwrite_cd_end (xostream &xos)
XIMOL_EXPORT xistreamread_cd_end (xistream &xis, int nb_read=0)
XIMOL_EXPORT xostreamwrite_cd_start (xostream &xos)
XIMOL_EXPORT xistreamread_cd_start (xistream &xis, int nb_read=0)
XIMOL_EXPORT xostreamwrite_cdata (xostream &xos, const xstring &xstr)
XIMOL_EXPORT xistreamread_cdata (xistream &xis, xstring &xstr)
XIMOL_EXPORT xostreamwrite_cd_sect (xostream &xos, const xstring &xstr)
XIMOL_EXPORT xistreamread_cd_sect (xistream &xis, xstring &xstr, int nb_char=0)
XIMOL_EXPORT xostreamwrite_eq (xostream &xos)
XIMOL_EXPORT xistreamread_eq (xistream &xis)
XIMOL_EXPORT bool is_version_num (const xstring &xstr)
XIMOL_EXPORT xostreamwrite_version_num (xostream &xos, const xstring &xstr)
XIMOL_EXPORT xistreamread_version_num (xistream &xis, xstring &xstr)
XIMOL_EXPORT xostreamwrite_version_info (xostream &xos, const xstring &xstr)
XIMOL_EXPORT xistreamread_version_info (xistream &xis, xstring &xstr, bool read_first_space=true)
XIMOL_EXPORT xistreamread_version_info (xistream &xis, bool read_first_space=true)
XIMOL_EXPORT bool is_enc_name (const xstring &xstr)
XIMOL_EXPORT xostreamwrite_enc_name (xostream &xos, const xstring &xstr)
XIMOL_EXPORT xistreamread_enc_name (xistream &xis, xstring &xstr)
XIMOL_EXPORT xostreamwrite_encoding_decl (xostream &xos, const xstring &xstr)
XIMOL_EXPORT xistreamread_encoding_decl (xistream &xis, xstring &xstr, bool read_first_space=true)
XIMOL_EXPORT xostreamwrite_sd_decl (xostream &xos, bool standalone)
XIMOL_EXPORT xistreamread_sd_decl (xistream &xis, bool &standalone, bool read_first_space=true)
XIMOL_EXPORT xostreamwrite_xml_decl (xostream &xos, const xstring &version_info, const xstring &encoding_decl=L"", const xstring &standalone_decl=L"")
XIMOL_EXPORT xistreamread_xml_decl (xistream &xis, xstring &version_info, xstring &encoding_decl, bool &standalone_decl, int nb_read=0)
XIMOL_EXPORT xostreamwrite_external_id (xostream &xos, const xstring &system_literal, const xstring &pub_id_literal=xstring())
XIMOL_EXPORT xistreamread_external_id (xistream &xis, xstring &system_literal, xstring &pub_id_literal)
XIMOL_EXPORT xostreamwrite_public_id (xostream &xos, const xstring &pub_id_literal)
XIMOL_EXPORT xistreamread_public_id (xistream &xis, xstring &pub_id_literal)
XIMOL_EXPORT xostreamwrite_notation_decl (xostream &xos, const xstring &name, const xstring &system_literal, const xstring &pub_id_literal)
XIMOL_EXPORT xistreamread_notation_decl (xistream &xis, xstring &name, xstring &system_literal, xstring &pub_id_literal, int nb_read=0)
XIMOL_EXPORT xostreamwrite_open_stag (xostream &xos, const xstring &name, const XIMOL_XML_NAMESPACE_PATH::attributes &att, const xstring &uri=xstring())
XIMOL_EXPORT xostreamwrite_open_stag (xostream &xos, const xstring &name, const xstring &uri=xstring())
XIMOL_EXPORT xostreamwrite_stag (xostream &xos, const xstring &name, const XIMOL_XML_NAMESPACE_PATH::attributes &att, const xstring &uri=xstring())
XIMOL_EXPORT xostreamwrite_stag (xostream &xos, const xstring &name)
XIMOL_EXPORT xostreamwrite_stag (xostream &xos, const xstring &name, const xstring &uri)
XIMOL_EXPORT xistreamread_open_stag (xistream &xis, xstring &name, XIMOL_XML_NAMESPACE_PATH::attributes &att, xstring &uri, int nb_read=0)
XIMOL_EXPORT xistreamread_open_stag (xistream &xis, xstring &name, xstring &uri, int nb_read=0)
XIMOL_EXPORT xistreamread_open_stag (xistream &xis, xstring &name, int nb_read=0)
XIMOL_EXPORT xistreamread_stag (xistream &xis, xstring &name, XIMOL_XML_NAMESPACE_PATH::attributes &att, xstring &uri, int nb_read=0)
XIMOL_EXPORT xistreamread_stag (xistream &xis, xstring &name, XIMOL_XML_NAMESPACE_PATH::attributes &att, int nb_read=0)
XIMOL_EXPORT xistreamread_stag (xistream &xis, xstring &name, xstring &uri, int nb_read=0)
XIMOL_EXPORT xistreamread_stag (xistream &xis, xstring &name, int nb_read=0)
XIMOL_EXPORT xostreamwrite_etag (xostream &xos, const xstring &name, const xstring &uri)
XIMOL_EXPORT xostreamwrite_etag (xostream &xos, const xstring &name)
XIMOL_EXPORT xostreamwrite_etag (xostream &xos)
XIMOL_EXPORT xistreamread_etag (xistream &xis, xstring &name, xstring &uri, int nb_read=0)
XIMOL_EXPORT xistreamread_etag (xistream &xis, xstring &name, int nb_read=0)
XIMOL_EXPORT xistreamread_etag (xistream &xis, int nb_read=0)
XIMOL_EXPORT xostreamwrite_ndata_decl (xostream &xos, const xstring &name)
XIMOL_EXPORT xistreamread_ndata_decl (xistream &xis, xstring &name, int nb_read=0)
XIMOL_EXPORT xistreamread_prolog_question (xistream &xis, int nb_read=0)
 read a prolog question tag

XIMOL_EXPORT xistreamread_prolog_exclamation (xistream &xis, int nb_read=0)
 read a prolog exclamation tag

XIMOL_EXPORT xistreamread_doctype_element (xistream &xis, int nb_read=0)
 read doctype elements


Variables

XIMOL_BEGIN_NAMESPACE class xostream
XIMOL_END_NAMESPACE XIMOL_XML_BEGIN_NAMESPACE
class 
attributes


Function Documentation

XIMOL_EXPORT bool is_string_with_forbidden_serie const xstring xstr,
bool(*  is_good_xchar)(xchar_t),
const::std::string &  forbidden_string
 

ForbiddenSerie ::= SetByFunction - (SetByFunction forbidden_string SetByFunction)

Definition at line 310 of file utils.cpp.

References read_string_with_forbidden_serie(), and xstring.

Referenced by is_char_data(), is_comment(), write_cdata(), write_pi(), and write_string_with_forbidden_serie().

XIMOL_EXPORT xistream& read_doctype_element xistream xis,
int  nb_read = 0
 

read doctype elements

Definition at line 3460 of file utils.cpp.

References _(), xistream::front(), xistream::get(), xistream::pop_front(), read_att_list_decl(), read_comment(), read_element_decl(), read_entity_decl(), read_notation_decl(), read_xchar(), XCHAR_EXCLAMATION_MARK, XCHAR_HYPHEN_MINUS, XCHAR_LATIN_CAPITAL_LETTER_A, XCHAR_LATIN_CAPITAL_LETTER_E, XCHAR_LATIN_CAPITAL_LETTER_L, XCHAR_LATIN_CAPITAL_LETTER_N, XCHAR_LESS_THAN_SIGN, xchar_t, XIMOL_AS_ERROR, and XIMOL_THROW.

Referenced by read_doctype_decl().

XIMOL_EXPORT xistream& read_prolog_exclamation xistream xis,
int  nb_read = 0
 

read a prolog exclamation tag

Definition at line 3437 of file utils.cpp.

References _(), xistream::front(), read_comment(), read_doctype_decl(), read_xchar(), XCHAR_EXCLAMATION_MARK, XCHAR_HYPHEN_MINUS, XCHAR_LATIN_CAPITAL_LETTER_D, XCHAR_LESS_THAN_SIGN, and xchar_t.

Referenced by read_prolog().

XIMOL_EXPORT xistream& read_prolog_question xistream xis,
int  nb_read = 0
 

read a prolog question tag

Definition at line 3328 of file utils.cpp.

References _(), xistream::front(), read_pi(), read_xchar(), read_xml_decl(), XCHAR_LATIN_CAPITAL_LETTER_X, XCHAR_LATIN_SMALL_LETTER_X, XCHAR_LESS_THAN_SIGN, XCHAR_QUESTION_MARK, and xchar_t.

Referenced by read_prolog().

XIMOL_XML_END_NAMESPACE XIMOL_PARSER_BEGIN_NAMESPACE XIMOL_EXPORT void write_xchar xostream xos,
xchar_t  xc
 

Put a char in the stream Do not use this function.

Parameters:
xos : the output stream
xc : the charater

Definition at line 129 of file utils.cpp.

Referenced by operator<<(), write_att_value(), write_cd_end(), write_cd_start(), write_char_ref(), write_comment(), write_encoding_decl(), write_entity_ref(), write_entity_value(), write_eq(), write_etag(), write_ge_decl(), write_ndata_decl(), write_notation_decl(), write_ns_att_name(), write_pe_decl(), write_pe_reference(), write_pi(), write_pubid_literal(), write_qname(), write_sd_decl(), write_space(), write_stag(), write_system_literal(), and write_version_info().


Variable Documentation

XIMOL_END_NAMESPACE XIMOL_XML_BEGIN_NAMESPACE class attributes
 

Definition at line 81 of file utils.hpp.

Referenced by attributes::operator=().

XIMOL_BEGIN_NAMESPACE class xostream
 

Definition at line 76 of file utils.hpp.



Donate to the XiMoL project SourceForge.net Logo If you have any questions about XiMoL, you could write to tournois@users.sourceforge.net.