summaryrefslogtreecommitdiffstats
path: root/src/xml/tqxml.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/xml/tqxml.cpp')
-rw-r--r--src/xml/tqxml.cpp1048
1 files changed, 524 insertions, 524 deletions
diff --git a/src/xml/tqxml.cpp b/src/xml/tqxml.cpp
index d6fe43026..591890976 100644
--- a/src/xml/tqxml.cpp
+++ b/src/xml/tqxml.cpp
@@ -174,7 +174,7 @@ static const signed char charLookupTable[256]={
/*
This function strips the TextDecl [77] ("<?xml ...?>") from the string \a
str. The stripped version is stored in \a str. If this function finds an
- invalid TextDecl, it returns FALSE, otherwise TRUE.
+ invalid TextDecl, it returns false, otherwise true.
This function is used for external entities since those can include an
TextDecl that must be stripped before inserting the entity.
@@ -192,10 +192,10 @@ static bool stripTextDecl( TQString& str )
));
TQString strTmp = str.replace( textDecl, "" );
if ( strTmp.length() != str.length() )
- return FALSE; // external entity has wrong TextDecl
+ return false; // external entity has wrong TextDecl
str = strTmp;
}
- return TRUE;
+ return true;
}
@@ -490,7 +490,7 @@ void TQXmlNamespaceSupport::splitName( const TQString& qname,
declared.
\a qname is the raw XML 1.0 name to be processed. \a isAttribute
- is TRUE if the name is an attribute name.
+ is true if the name is an attribute name.
This function stores the namespace URI in \a nsuri (which will be
set to TQString::null if the raw name has an undeclared prefix),
@@ -1021,14 +1021,14 @@ TQChar TQXmlInputSource::next()
{
if ( pos >= length ) {
if ( nextReturnedEndOfData ) {
- nextReturnedEndOfData = FALSE;
+ nextReturnedEndOfData = false;
fetchData();
if ( pos >= length ) {
return EndOfDocument;
}
return next();
}
- nextReturnedEndOfData = TRUE;
+ nextReturnedEndOfData = true;
return EndOfData;
}
return unicode[pos++];
@@ -1043,7 +1043,7 @@ TQChar TQXmlInputSource::next()
*/
void TQXmlInputSource::reset()
{
- nextReturnedEndOfData = FALSE;
+ nextReturnedEndOfData = false;
pos = 0;
}
@@ -1072,7 +1072,7 @@ void TQXmlInputSource::setData( const TQString& dat )
unicode = str.unicode();
pos = 0;
length = str.length();
- nextReturnedEndOfData = FALSE;
+ nextReturnedEndOfData = false;
}
/*!
@@ -1133,9 +1133,9 @@ void TQXmlInputSource::fetchData()
TQString and returns it. It tries its best to get the correct
encoding for the XML file.
- If \a beginning is TRUE, this function assumes that the data
+ If \a beginning is true, this function assumes that the data
starts at the beginning of a new XML document and looks for an
- encoding declaration. If \a beginning is FALSE, it converts the
+ encoding declaration. If \a beginning is false, it converts the
raw data using the encoding determined from prior calls.
*/
TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning )
@@ -1274,7 +1274,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
to setDocumentLocator(), and before any other functions in this
class or in the TQXmlDTDHandler class are called.
- If this function returns FALSE the reader stops parsing and
+ If this function returns false the reader stops parsing and
reports an error. The reader uses the function errorString() to
get the error message.
@@ -1289,7 +1289,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
is called after the reader has read all input or has abandoned
parsing because of a fatal error.
- If this function returns FALSE the reader stops parsing and
+ If this function returns false the reader stops parsing and
reports an error. The reader uses the function errorString() to
get the error message.
@@ -1314,7 +1314,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
The argument \a prefix is the namespace prefix being declared and
the argument \a uri is the namespace URI the prefix is mapped to.
- If this function returns FALSE the reader stops parsing and
+ If this function returns false the reader stops parsing and
reports an error. The reader uses the function errorString() to
get the error message.
@@ -1329,7 +1329,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
The reader calls this function to signal the end of a prefix
mapping for the prefix \a prefix.
- If this function returns FALSE the reader stops parsing and
+ If this function returns false the reader stops parsing and
reports an error. The reader uses the function errorString() to
get the error message.
@@ -1353,7 +1353,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
The attribute list provided only contains attributes with explicit
values. The attribute list contains attributes used for namespace
declaration (i.e. attributes starting with xmlns) only if the
- namespace-prefix property of the reader is TRUE.
+ namespace-prefix property of the reader is true.
The argument \a namespaceURI is the namespace URI, or
TQString::null if the element has no namespace URI or if no
@@ -1363,7 +1363,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
the attributes attached to the element. If there are no
attributes, \a atts is an empty attributes object.
- If this function returns FALSE the reader stops parsing and
+ If this function returns false the reader stops parsing and
reports an error. The reader uses the function errorString() to
get the error message.
@@ -1379,7 +1379,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
tag with the qualified name \a qName, the local name \a localName
and the namespace URI \a namespaceURI.
- If this function returns FALSE the reader stops parsing and
+ If this function returns false the reader stops parsing and
reports an error. The reader uses the function errorString() to
get the error message.
@@ -1405,7 +1405,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
one chunk; e.g. a reader might want to report "a\<b" in three
characters() events ("a ", "\<" and " b").
- If this function returns FALSE the reader stops parsing and
+ If this function returns false the reader stops parsing and
reports an error. The reader uses the function errorString() to
get the error message.
*/
@@ -1416,7 +1416,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
Some readers may use this function to report each chunk of
whitespace in element content. The whitespace is reported in \a ch.
- If this function returns FALSE the reader stops parsing and
+ If this function returns false the reader stops parsing and
reports an error. The reader uses the function errorString() to
get the error message.
*/
@@ -1430,7 +1430,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
\a target is the target name of the processing instruction and \a
data is the data in the processing instruction.
- If this function returns FALSE the reader stops parsing and
+ If this function returns false the reader stops parsing and
reports an error. The reader uses the function errorString() to
get the error message.
*/
@@ -1443,7 +1443,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
do so they report that they skipped the entity called \a name by
calling this function.
- If this function returns FALSE the reader stops parsing and
+ If this function returns false the reader stops parsing and
reports an error. The reader uses the function errorString() to
get the error message.
*/
@@ -1452,7 +1452,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
\fn TQString TQXmlContentHandler::errorString()
The reader calls this function to get an error string, e.g. if any
- of the handler functions returns FALSE.
+ of the handler functions returns false.
*/
@@ -1490,7 +1490,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
XML 1.0 specification. Details of the warning are stored in \a
exception.
- If this function returns FALSE the reader stops parsing and
+ If this function returns false the reader stops parsing and
reports an error. The reader uses the function errorString() to
get the error message.
*/
@@ -1506,7 +1506,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
The reader must continue to provide normal parsing events after
invoking this function.
- If this function returns FALSE the reader stops parsing and
+ If this function returns false the reader stops parsing and
reports an error. The reader uses the function errorString() to
get the error message.
*/
@@ -1517,7 +1517,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
A reader must use this function to report a non-recoverable error.
Details of the error are stored in \a exception.
- If this function returns TRUE the reader might try to go on
+ If this function returns true the reader might try to go on
parsing and reporting further errors; but no regular parsing
events are reported.
*/
@@ -1526,7 +1526,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
\fn TQString TQXmlErrorHandler::errorString()
The reader calls this function to get an error string if any of
- the handler functions returns FALSE.
+ the handler functions returns false.
*/
@@ -1567,7 +1567,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
notation's public identifier and \a systemId is the notation's
system identifier.
- If this function returns FALSE the reader stops parsing and
+ If this function returns false the reader stops parsing and
reports an error. The reader uses the function errorString() to
get the error message.
*/
@@ -1583,7 +1583,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
identifier and \a notationName is the name of the associated
notation.
- If this function returns FALSE the reader stops parsing and
+ If this function returns false the reader stops parsing and
reports an error. The reader uses the function errorString() to
get the error message.
*/
@@ -1592,7 +1592,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
\fn TQString TQXmlDTDHandler::errorString()
The reader calls this function to get an error string if any of
- the handler functions returns FALSE.
+ the handler functions returns false.
*/
@@ -1638,7 +1638,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
non-zero it must point to an input source which the reader uses
instead.
- If this function returns FALSE the reader stops parsing and
+ If this function returns false the reader stops parsing and
reports an error. The reader uses the function errorString() to
get the error message.
*/
@@ -1647,7 +1647,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
\fn TQString TQXmlEntityResolver::errorString()
The reader calls this function to get an error string if any of
- the handler functions returns FALSE.
+ the handler functions returns false.
*/
@@ -1700,7 +1700,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
All declarations reported through TQXmlDTDHandler or
TQXmlDeclHandler appear between the startDTD() and endDTD() calls.
- If this function returns FALSE the reader stops parsing and
+ If this function returns false the reader stops parsing and
reports an error. The reader uses the function errorString() to
get the error message.
@@ -1713,7 +1713,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
The reader calls this function to report the end of a DTD
declaration, if any.
- If this function returns FALSE the reader stops parsing and
+ If this function returns false the reader stops parsing and
reports an error. The reader uses the function errorString() to
get the error message.
@@ -1730,7 +1730,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
TQXmlContentHandler::skippedEntity() and not through this
function.
- If this function returns FALSE the reader stops parsing and
+ If this function returns false the reader stops parsing and
reports an error. The reader uses the function errorString() to
get the error message.
@@ -1747,7 +1747,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
call. The calls to startEntity() and endEntity() are properly
nested.
- If this function returns FALSE the reader stops parsing and
+ If this function returns false the reader stops parsing and
reports an error. The reader uses the function errorString() to
get the error message.
@@ -1762,7 +1762,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
TQXmlContentHandler::characters() function. This function is
intended only to report the boundary.
- If this function returns FALSE the reader stops parsing and
+ If this function returns false the reader stops parsing and
reports an error. The reader uses the function errorString() to
get the error message.
@@ -1775,7 +1775,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
The reader calls this function to report the end of a CDATA
section.
- If this function returns FALSE the reader stops parsing and reports
+ If this function returns false the reader stops parsing and reports
an error. The reader uses the function errorString() to get the error
message.
@@ -1788,7 +1788,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
The reader calls this function to report an XML comment anywhere
in the document. It reports the text of the comment in \a ch.
- If this function returns FALSE the reader stops parsing and
+ If this function returns false the reader stops parsing and
reports an error. The reader uses the function errorString() to
get the error message.
*/
@@ -1797,7 +1797,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
\fn TQString TQXmlLexicalHandler::errorString()
The reader calls this function to get an error string if any of
- the handler functions returns FALSE.
+ the handler functions returns false.
*/
@@ -1843,7 +1843,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
default value in \a value. If no default value is specified in the
XML file, \a value is TQString::null.
- If this function returns FALSE the reader stops parsing and
+ If this function returns false the reader stops parsing and
reports an error. The reader uses the function errorString() to
get the error message.
*/
@@ -1857,7 +1857,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
The reader passes the name of the entity in \a name and the value
of the entity in \a value.
- If this function returns FALSE the reader stops parsing and
+ If this function returns false the reader stops parsing and
reports an error. The reader uses the function errorString() to
get the error message.
*/
@@ -1874,7 +1874,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
systemId. If there is no public identifier specified, it passes
TQString::null in \a publicId.
- If this function returns FALSE the reader stops parsing and
+ If this function returns false the reader stops parsing and
reports an error. The reader uses the function errorString() to
get the error message.
*/
@@ -1883,7 +1883,7 @@ TQString TQXmlInputSource::fromRawData( const TQByteArray &data, bool beginning
\fn TQString TQXmlDeclHandler::errorString()
The reader calls this function to get an error string if any of
- the handler functions returns FALSE.
+ the handler functions returns false.
*/
@@ -1938,7 +1938,7 @@ void TQXmlDefaultHandler::setDocumentLocator( TQXmlLocator* )
*/
bool TQXmlDefaultHandler::startDocument()
{
- return TRUE;
+ return true;
}
/*!
@@ -1948,7 +1948,7 @@ bool TQXmlDefaultHandler::startDocument()
*/
bool TQXmlDefaultHandler::endDocument()
{
- return TRUE;
+ return true;
}
/*!
@@ -1958,7 +1958,7 @@ bool TQXmlDefaultHandler::endDocument()
*/
bool TQXmlDefaultHandler::startPrefixMapping( const TQString&, const TQString& )
{
- return TRUE;
+ return true;
}
/*!
@@ -1968,7 +1968,7 @@ bool TQXmlDefaultHandler::startPrefixMapping( const TQString&, const TQString& )
*/
bool TQXmlDefaultHandler::endPrefixMapping( const TQString& )
{
- return TRUE;
+ return true;
}
/*!
@@ -1979,7 +1979,7 @@ bool TQXmlDefaultHandler::endPrefixMapping( const TQString& )
bool TQXmlDefaultHandler::startElement( const TQString&, const TQString&,
const TQString&, const TQXmlAttributes& )
{
- return TRUE;
+ return true;
}
/*!
@@ -1990,7 +1990,7 @@ bool TQXmlDefaultHandler::startElement( const TQString&, const TQString&,
bool TQXmlDefaultHandler::endElement( const TQString&, const TQString&,
const TQString& )
{
- return TRUE;
+ return true;
}
/*!
@@ -2000,7 +2000,7 @@ bool TQXmlDefaultHandler::endElement( const TQString&, const TQString&,
*/
bool TQXmlDefaultHandler::characters( const TQString& )
{
- return TRUE;
+ return true;
}
/*!
@@ -2010,7 +2010,7 @@ bool TQXmlDefaultHandler::characters( const TQString& )
*/
bool TQXmlDefaultHandler::ignorableWhitespace( const TQString& )
{
- return TRUE;
+ return true;
}
/*!
@@ -2021,7 +2021,7 @@ bool TQXmlDefaultHandler::ignorableWhitespace( const TQString& )
bool TQXmlDefaultHandler::processingInstruction( const TQString&,
const TQString& )
{
- return TRUE;
+ return true;
}
/*!
@@ -2031,7 +2031,7 @@ bool TQXmlDefaultHandler::processingInstruction( const TQString&,
*/
bool TQXmlDefaultHandler::skippedEntity( const TQString& )
{
- return TRUE;
+ return true;
}
/*!
@@ -2041,7 +2041,7 @@ bool TQXmlDefaultHandler::skippedEntity( const TQString& )
*/
bool TQXmlDefaultHandler::warning( const TQXmlParseException& )
{
- return TRUE;
+ return true;
}
/*!
@@ -2051,7 +2051,7 @@ bool TQXmlDefaultHandler::warning( const TQXmlParseException& )
*/
bool TQXmlDefaultHandler::error( const TQXmlParseException& )
{
- return TRUE;
+ return true;
}
/*!
@@ -2061,7 +2061,7 @@ bool TQXmlDefaultHandler::error( const TQXmlParseException& )
*/
bool TQXmlDefaultHandler::fatalError( const TQXmlParseException& )
{
- return TRUE;
+ return true;
}
/*!
@@ -2072,7 +2072,7 @@ bool TQXmlDefaultHandler::fatalError( const TQXmlParseException& )
bool TQXmlDefaultHandler::notationDecl( const TQString&, const TQString&,
const TQString& )
{
- return TRUE;
+ return true;
}
/*!
@@ -2083,7 +2083,7 @@ bool TQXmlDefaultHandler::notationDecl( const TQString&, const TQString&,
bool TQXmlDefaultHandler::unparsedEntityDecl( const TQString&, const TQString&,
const TQString&, const TQString& )
{
- return TRUE;
+ return true;
}
/*!
@@ -2096,7 +2096,7 @@ bool TQXmlDefaultHandler::resolveEntity( const TQString&, const TQString&,
TQXmlInputSource*& ret )
{
ret = 0;
- return TRUE;
+ return true;
}
/*!
@@ -2116,7 +2116,7 @@ TQString TQXmlDefaultHandler::errorString()
*/
bool TQXmlDefaultHandler::startDTD( const TQString&, const TQString&, const TQString& )
{
- return TRUE;
+ return true;
}
/*!
@@ -2126,7 +2126,7 @@ bool TQXmlDefaultHandler::startDTD( const TQString&, const TQString&, const TQSt
*/
bool TQXmlDefaultHandler::endDTD()
{
- return TRUE;
+ return true;
}
/*!
@@ -2136,7 +2136,7 @@ bool TQXmlDefaultHandler::endDTD()
*/
bool TQXmlDefaultHandler::startEntity( const TQString& )
{
- return TRUE;
+ return true;
}
/*!
@@ -2146,7 +2146,7 @@ bool TQXmlDefaultHandler::startEntity( const TQString& )
*/
bool TQXmlDefaultHandler::endEntity( const TQString& )
{
- return TRUE;
+ return true;
}
/*!
@@ -2156,7 +2156,7 @@ bool TQXmlDefaultHandler::endEntity( const TQString& )
*/
bool TQXmlDefaultHandler::startCDATA()
{
- return TRUE;
+ return true;
}
/*!
@@ -2166,7 +2166,7 @@ bool TQXmlDefaultHandler::startCDATA()
*/
bool TQXmlDefaultHandler::endCDATA()
{
- return TRUE;
+ return true;
}
/*!
@@ -2176,7 +2176,7 @@ bool TQXmlDefaultHandler::endCDATA()
*/
bool TQXmlDefaultHandler::comment( const TQString& )
{
- return TRUE;
+ return true;
}
/*!
@@ -2186,7 +2186,7 @@ bool TQXmlDefaultHandler::comment( const TQString& )
*/
bool TQXmlDefaultHandler::attributeDecl( const TQString&, const TQString&, const TQString&, const TQString&, const TQString& )
{
- return TRUE;
+ return true;
}
/*!
@@ -2196,7 +2196,7 @@ bool TQXmlDefaultHandler::attributeDecl( const TQString&, const TQString&, const
*/
bool TQXmlDefaultHandler::internalEntityDecl( const TQString&, const TQString& )
{
- return TRUE;
+ return true;
}
/*!
@@ -2206,7 +2206,7 @@ bool TQXmlDefaultHandler::internalEntityDecl( const TQString&, const TQString& )
*/
bool TQXmlDefaultHandler::externalEntityDecl( const TQString&, const TQString&, const TQString& )
{
- return TRUE;
+ return true;
}
@@ -2223,7 +2223,7 @@ private:
inline TQXmlSimpleReaderPrivate()
{
parseStack = 0;
- undefEntityInAttrHack = FALSE;
+ undefEntityInAttrHack = false;
}
inline ~TQXmlSimpleReaderPrivate()
@@ -2403,8 +2403,8 @@ private:
is returned. If no such feature exists the return value is
undefined.
- If \a ok is not 0: \a *ok is set to TRUE if the reader has the
- feature called \a name; otherwise \a *ok is set to FALSE.
+ If \a ok is not 0: \a *ok is set to true if the reader has the
+ feature called \a name; otherwise \a *ok is set to false.
\sa setFeature() hasFeature()
*/
@@ -2421,8 +2421,8 @@ private:
/*!
\fn bool TQXmlReader::hasFeature( const TQString& name ) const
- Returns \c TRUE if the reader has the feature called \a name;
- otherwise returns FALSE.
+ Returns \c true if the reader has the feature called \a name;
+ otherwise returns false.
\sa feature() setFeature()
*/
@@ -2434,7 +2434,7 @@ private:
value of the property; otherwise the return value is undefined.
If \a ok is not 0: if the reader has the \a name property \a *ok
- is set to TRUE; otherwise \a *ok is set to FALSE.
+ is set to true; otherwise \a *ok is set to false.
\sa setProperty() hasProperty()
*/
@@ -2451,8 +2451,8 @@ private:
/*!
\fn bool TQXmlReader::hasProperty( const TQString& name ) const
- Returns TRUE if the reader has the property \a name; otherwise
- returns FALSE.
+ Returns true if the reader has the property \a name; otherwise
+ returns false.
\sa property() setProperty()
*/
@@ -2563,8 +2563,8 @@ private:
/*!
\fn bool TQXmlReader::parse( const TQXmlInputSource* input )
- Reads an XML document from \a input and parses it. Returns TRUE if
- the parsing was successful; otherwise returns FALSE.
+ Reads an XML document from \a input and parses it. Returns true if
+ the parsing was successful; otherwise returns false.
*/
@@ -2668,11 +2668,11 @@ inline void TQXmlSimpleReader::refClear()
Constructs a simple XML reader with the following feature settings:
\table
\header \i Feature \i Setting
- \row \i \e http://xml.org/sax/features/namespaces \i TRUE
- \row \i \e http://xml.org/sax/features/namespace-prefixes \i FALSE
+ \row \i \e http://xml.org/sax/features/namespaces \i true
+ \row \i \e http://xml.org/sax/features/namespace-prefixes \i false
\row \i \e http://trolltech.com/xml/features/report-whitespace-only-CharData
- \i TRUE
- \row \i \e http://trolltech.com/xml/features/report-start-end-entity \i FALSE
+ \i true
+ \row \i \e http://trolltech.com/xml/features/report-start-end-entity \i false
\endtable
More information about features can be found in the \link
@@ -2694,10 +2694,10 @@ TQXmlSimpleReader::TQXmlSimpleReader()
declHnd = 0;
// default feature settings
- d->useNamespaces = TRUE;
- d->useNamespacePrefixes = FALSE;
- d->reportWhitespaceCharData = TRUE;
- d->reportEntities = FALSE;
+ d->useNamespaces = true;
+ d->useNamespacePrefixes = false;
+ d->reportWhitespaceCharData = true;
+ d->reportEntities = false;
}
/*!
@@ -2715,7 +2715,7 @@ TQXmlSimpleReader::~TQXmlSimpleReader()
bool TQXmlSimpleReader::feature( const TQString& name, bool *ok ) const
{
if ( ok != 0 )
- *ok = TRUE;
+ *ok = true;
if ( name == "http://xml.org/sax/features/namespaces" ) {
return d->useNamespaces;
} else if ( name == "http://xml.org/sax/features/namespace-prefixes" ) {
@@ -2727,9 +2727,9 @@ bool TQXmlSimpleReader::feature( const TQString& name, bool *ok ) const
} else {
tqWarning( "Unknown feature %s", name.latin1() );
if ( ok != 0 )
- *ok = FALSE;
+ *ok = false;
}
- return FALSE;
+ return false;
}
/*!
@@ -2741,21 +2741,21 @@ bool TQXmlSimpleReader::feature( const TQString& name, bool *ok ) const
\table
\header \i Feature \i Notes
\row \i \e http://xml.org/sax/features/namespaces
- \i If this feature is TRUE, namespace processing is
+ \i If this feature is true, namespace processing is
performed.
\row \i \e http://xml.org/sax/features/namespace-prefixes
- \i If this feature is TRUE, the the original prefixed names
+ \i If this feature is true, the the original prefixed names
and attributes used for namespace declarations are
reported.
\row \i \e http://trolltech.com/xml/features/report-whitespace-only-CharData
- \i If this feature is TRUE, CharData that only contain
+ \i If this feature is true, CharData that only contain
whitespace are not ignored, but are reported via
TQXmlContentHandler::characters().
\row \i \e http://trolltech.com/xml/features/report-start-end-entity
- \i If this feature is TRUE, the parser reports
+ \i If this feature is true, the parser reports
TQXmlContentHandler::startEntity() and
TQXmlContentHandler::endEntity() events. So character data
- might be reported in chunks. If this feature is FALSE, the
+ might be reported in chunks. If this feature is false, the
parser does not report those events, but rather silently
substitutes the entities and reports the character data in
one chunk.
@@ -2766,7 +2766,7 @@ bool TQXmlSimpleReader::feature( const TQString& name, bool *ok ) const
\printline reader
\skipto setFeature
\printline setFeature
- \printline TRUE
+ \printline true
(Code taken from xml/tagreader-with-features/tagreader.cpp)
@@ -2795,9 +2795,9 @@ bool TQXmlSimpleReader::hasFeature( const TQString& name ) const
|| name == "http://xml.org/sax/features/namespace-prefixes"
|| name == "http://trolltech.com/xml/features/report-whitespace-only-CharData"
|| name == "http://trolltech.com/xml/features/report-start-end-entity" ) {
- return TRUE;
+ return true;
} else {
- return FALSE;
+ return false;
}
}
@@ -2806,7 +2806,7 @@ bool TQXmlSimpleReader::hasFeature( const TQString& name ) const
void* TQXmlSimpleReader::property( const TQString&, bool *ok ) const
{
if ( ok != 0 )
- *ok = FALSE;
+ *ok = false;
return 0;
}
@@ -2821,7 +2821,7 @@ void TQXmlSimpleReader::setProperty( const TQString&, void* )
*/
bool TQXmlSimpleReader::hasProperty( const TQString& ) const
{
- return FALSE;
+ return false;
}
/*!
@@ -2903,7 +2903,7 @@ TQXmlDeclHandler* TQXmlSimpleReader::declHandler() const
*/
bool TQXmlSimpleReader::parse( const TQXmlInputSource& input )
{
- return parse( &input, FALSE );
+ return parse( &input, false );
}
/*!
@@ -2911,14 +2911,14 @@ bool TQXmlSimpleReader::parse( const TQXmlInputSource& input )
*/
bool TQXmlSimpleReader::parse( const TQXmlInputSource* input )
{
- return parse( input, FALSE );
+ return parse( input, false );
}
/*!
- Reads an XML document from \a input and parses it. Returns FALSE
- if the parsing detects an error; otherwise returns TRUE.
+ Reads an XML document from \a input and parses it. Returns false
+ if the parsing detects an error; otherwise returns true.
- If \a incremental is TRUE, the parser does not return FALSE when
+ If \a incremental is true, the parser does not return false when
it reaches the end of the \a input without reaching the end of the
XML file. Instead it stores the state of the parser so that
parsing can be continued at a later stage when more data is
@@ -2928,11 +2928,11 @@ bool TQXmlSimpleReader::parse( const TQXmlInputSource* input )
input souce. This means that you should not delete the input
source \a input until you've finished your calls to
parseContinue(). If you call this function with \a incremental
- TRUE whilst an incremental parse is in progress a new parsing
+ true whilst an incremental parse is in progress a new parsing
session will be started and the previous session lost.
- If \a incremental is FALSE, this function behaves like the normal
- parse function, i.e. it returns FALSE when the end of input is
+ If \a incremental is false, this function behaves like the normal
+ parse function, i.e. it returns false when the end of input is
reached without reaching the end of the XML file and the parsing
cannot be continued.
@@ -2953,7 +2953,7 @@ bool TQXmlSimpleReader::parse( const TQXmlInputSource *input, bool incremental )
if ( !contentHnd->startDocument() ) {
reportParseError( contentHnd->errorString() );
d->tags.clear();
- return FALSE;
+ return false;
}
}
return parseBeginOrContinue( 0, incremental );
@@ -2963,9 +2963,9 @@ bool TQXmlSimpleReader::parse( const TQXmlInputSource *input, bool incremental )
Continues incremental parsing; this function reads the input from
the TQXmlInputSource that was specified with the last parse()
command. To use this function, you \e must have called parse()
- with the incremental argument set to TRUE.
+ with the incremental argument set to true.
- Returns FALSE if a parsing error occurs; otherwise returns TRUE.
+ Returns false if a parsing error occurs; otherwise returns true.
If the input source returns an empty string for the function
TQXmlInputSource::data(), then this means that the end of the XML
@@ -2980,7 +2980,7 @@ bool TQXmlSimpleReader::parse( const TQXmlInputSource *input, bool incremental )
This function assumes that the end of the XML document is reached
if the TQXmlInputSource::next() function returns
TQXmlInputSource::EndOfDocument. If the parser has not finished
- parsing when it encounters this symbol, it is an error and FALSE
+ parsing when it encounters this symbol, it is an error and false
is returned.
\sa parse() TQXmlInputSource::next()
@@ -2988,10 +2988,10 @@ bool TQXmlSimpleReader::parse( const TQXmlInputSource *input, bool incremental )
bool TQXmlSimpleReader::parseContinue()
{
if ( d->parseStack == 0 || d->parseStack->isEmpty() )
- return FALSE;
+ return false;
initData();
int state = d->parseStack->pop().state;
- return parseBeginOrContinue( state, TRUE );
+ return parseBeginOrContinue( state, true );
}
/*
@@ -3005,10 +3005,10 @@ bool TQXmlSimpleReader::parseBeginOrContinue( int state, bool incremental )
if ( !parseProlog() ) {
if ( incremental && d->error.isNull() ) {
pushParseState( 0, 0 );
- return TRUE;
+ return true;
} else {
d->tags.clear();
- return FALSE;
+ return false;
}
}
state = 1;
@@ -3017,10 +3017,10 @@ bool TQXmlSimpleReader::parseBeginOrContinue( int state, bool incremental )
if ( !parseElement() ) {
if ( incremental && d->error.isNull() ) {
pushParseState( 0, 1 );
- return TRUE;
+ return true;
} else {
d->tags.clear();
- return FALSE;
+ return false;
}
}
state = 2;
@@ -3030,23 +3030,23 @@ bool TQXmlSimpleReader::parseBeginOrContinue( int state, bool incremental )
if ( !parseMisc() ) {
if ( incremental && d->error.isNull() ) {
pushParseState( 0, 2 );
- return TRUE;
+ return true;
} else {
d->tags.clear();
- return FALSE;
+ return false;
}
}
}
if ( !atEndOrig && incremental ) {
// we parsed something at all, so be prepared to come back later
pushParseState( 0, 2 );
- return TRUE;
+ return true;
}
// is stack empty?
if ( !d->tags.isEmpty() && !d->error.isNull() ) {
reportParseError( XMLERR_UNEXPECTEDEOF );
d->tags.clear();
- return FALSE;
+ return false;
}
// call the handler
if ( contentHnd ) {
@@ -3054,17 +3054,17 @@ bool TQXmlSimpleReader::parseBeginOrContinue( int state, bool incremental )
d->parseStack = 0;
if ( !contentHnd->endDocument() ) {
reportParseError( contentHnd->errorString() );
- return FALSE;
+ return false;
}
}
- return TRUE;
+ return true;
}
//
// The following private parse functions have another semantics for the return
-// value: They return TRUE iff parsing has finished successfully (i.e. the end
-// of the XML file must be reached!). If one of these functions return FALSE,
-// there is only an error when d->error.isNULL() is also FALSE.
+// value: They return true iff parsing has finished successfully (i.e. the end
+// of the XML file must be reached!). If one of these functions return false,
+// there is only an error when d->error.isNULL() is also false.
//
/*
@@ -3100,7 +3100,7 @@ bool TQXmlSimpleReader::parseBeginOrContinue( int state, bool incremental )
(6)
(6a) if ( atEnd() ) {
unexpectedEof( &TQXmlSimpleReader::parseNmtoken, state );
- return FALSE;
+ return false;
}
(6b) if (determineNameChar(c) != NotName) {
...
@@ -3176,8 +3176,8 @@ bool TQXmlSimpleReader::parseProlog()
signed char input;
if ( d->parseStack==0 || d->parseStack->isEmpty() ) {
- d->xmldecl_possible = TRUE;
- d->doctype_read = FALSE;
+ d->xmldecl_possible = true;
+ d->doctype_read = false;
state = Init;
} else {
state = d->parseStack->pop().state;
@@ -3194,7 +3194,7 @@ bool TQXmlSimpleReader::parseProlog()
}
if ( !(this->*function)() ) {
parseFailed( &TQXmlSimpleReader::parseProlog, state );
- return FALSE;
+ return false;
}
}
}
@@ -3204,16 +3204,16 @@ bool TQXmlSimpleReader::parseProlog()
case DocType:
if ( d->doctype_read ) {
reportParseError( XMLERR_MORETHANONEDOCTYPE );
- return FALSE;
+ return false;
} else {
- d->doctype_read = FALSE;
+ d->doctype_read = false;
}
break;
case Comment:
if ( lexicalHnd ) {
if ( !lexicalHnd->comment( string() ) ) {
reportParseError( lexicalHnd->errorString() );
- return FALSE;
+ return false;
}
}
state = CommentR;
@@ -3237,29 +3237,29 @@ bool TQXmlSimpleReader::parseProlog()
}
if ( !contentHnd->processingInstruction( "xml", value ) ) {
reportParseError( contentHnd->errorString() );
- return FALSE;
+ return false;
}
} else {
if ( !contentHnd->processingInstruction( name(), string() ) ) {
reportParseError( contentHnd->errorString() );
- return FALSE;
+ return false;
}
}
}
// XML declaration only on first position possible
- d->xmldecl_possible = FALSE;
+ d->xmldecl_possible = false;
state = PInstrR;
break;
case Done:
- return TRUE;
+ return true;
case -1:
reportParseError( XMLERR_ERRORPARSINGELEMENT );
- return FALSE;
+ return false;
}
if ( atEnd() ) {
unexpectedEof( &TQXmlSimpleReader::parseProlog, state );
- return FALSE;
+ return false;
}
if ( is_S(c) ) {
input = InpWs;
@@ -3281,10 +3281,10 @@ bool TQXmlSimpleReader::parseProlog()
switch ( state ) {
case EatWS:
// XML declaration only on first position possible
- d->xmldecl_possible = FALSE;
+ d->xmldecl_possible = false;
if ( !eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseProlog, state );
- return FALSE;
+ return false;
}
break;
case Lt:
@@ -3292,20 +3292,20 @@ bool TQXmlSimpleReader::parseProlog()
break;
case Em:
// XML declaration only on first position possible
- d->xmldecl_possible = FALSE;
+ d->xmldecl_possible = false;
next();
break;
case DocType:
if ( !parseDoctype() ) {
parseFailed( &TQXmlSimpleReader::parseProlog, state );
- return FALSE;
+ return false;
}
break;
case Comment:
case CommentR:
if ( !parseComment() ) {
parseFailed( &TQXmlSimpleReader::parseProlog, state );
- return FALSE;
+ return false;
}
break;
case PInstr:
@@ -3313,7 +3313,7 @@ bool TQXmlSimpleReader::parseProlog()
d->parsePI_xmldecl = d->xmldecl_possible;
if ( !parsePI() ) {
parseFailed( &TQXmlSimpleReader::parseProlog, state );
- return FALSE;
+ return false;
}
break;
}
@@ -3382,7 +3382,7 @@ bool TQXmlSimpleReader::parseElement()
}
if ( !(this->*function)() ) {
parseFailed( &TQXmlSimpleReader::parseElement, state );
- return FALSE;
+ return false;
}
}
}
@@ -3399,23 +3399,23 @@ bool TQXmlSimpleReader::parseElement()
break;
case ETagBegin2:
if ( !processElementETagBegin2() )
- return FALSE;
+ return false;
break;
case Attrib:
if ( !processElementAttribute() )
- return FALSE;
+ return false;
state = AttribPro;
break;
case Done:
- return TRUE;
+ return true;
case -1:
reportParseError( XMLERR_ERRORPARSINGELEMENT );
- return FALSE;
+ return false;
}
if ( atEnd() ) {
unexpectedEof( &TQXmlSimpleReader::parseElement, state );
- return FALSE;
+ return false;
}
if (fastDetermineNameChar(c) == NameBeginning) {
@@ -3433,10 +3433,10 @@ bool TQXmlSimpleReader::parseElement()
switch ( state ) {
case ReadName:
- d->parseName_useRef = FALSE;
+ d->parseName_useRef = false;
if ( !parseName() ) {
parseFailed( &TQXmlSimpleReader::parseElement, state );
- return FALSE;
+ return false;
}
break;
case Ws1:
@@ -3444,7 +3444,7 @@ bool TQXmlSimpleReader::parseElement()
case Ws3:
if ( !eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseElement, state );
- return FALSE;
+ return false;
}
break;
case STagEnd:
@@ -3453,15 +3453,15 @@ bool TQXmlSimpleReader::parseElement()
const TQString &tagsTop = d->tags.top();
if ( d->useNamespaces ) {
TQString uri, lname;
- d->namespaceSupport.processName(tagsTop, FALSE, uri, lname);
+ d->namespaceSupport.processName(tagsTop, false, uri, lname);
if (!contentHnd->startElement(uri, lname, tagsTop, d->attList)) {
reportParseError( contentHnd->errorString() );
- return FALSE;
+ return false;
}
} else {
if (!contentHnd->startElement(TQString::null, TQString::null, tagsTop, d->attList)) {
reportParseError( contentHnd->errorString() );
- return FALSE;
+ return false;
}
}
}
@@ -3470,7 +3470,7 @@ bool TQXmlSimpleReader::parseElement()
case STagEnd2:
if ( !parseContent() ) {
parseFailed( &TQXmlSimpleReader::parseElement, state );
- return FALSE;
+ return false;
}
break;
case ETagBegin:
@@ -3478,19 +3478,19 @@ bool TQXmlSimpleReader::parseElement()
break;
case ETagBegin2:
// get the name of the tag
- d->parseName_useRef = FALSE;
+ d->parseName_useRef = false;
if ( !parseName() ) {
parseFailed( &TQXmlSimpleReader::parseElement, state );
- return FALSE;
+ return false;
}
break;
case EmptyTag:
if ( d->tags.isEmpty() ) {
reportParseError( XMLERR_TAGMISMATCH );
- return FALSE;
+ return false;
}
if ( !processElementEmptyTag() )
- return FALSE;
+ return false;
next();
break;
case Attrib:
@@ -3498,7 +3498,7 @@ bool TQXmlSimpleReader::parseElement()
// get name and value of attribute
if ( !parseAttribute() ) {
parseFailed( &TQXmlSimpleReader::parseElement, state );
- return FALSE;
+ return false;
}
break;
case Done:
@@ -3509,7 +3509,7 @@ bool TQXmlSimpleReader::parseElement()
}
/*
Helper to break down the size of the code in the case statement.
- Return FALSE on error, otherwise TRUE.
+ Return false on error, otherwise true.
*/
bool TQXmlSimpleReader::processElementEmptyTag()
{
@@ -3518,15 +3518,15 @@ bool TQXmlSimpleReader::processElementEmptyTag()
if ( contentHnd ) {
if ( d->useNamespaces ) {
// report startElement first...
- d->namespaceSupport.processName( d->tags.top(), FALSE, uri, lname );
+ d->namespaceSupport.processName( d->tags.top(), false, uri, lname );
if ( !contentHnd->startElement( uri, lname, d->tags.top(), d->attList ) ) {
reportParseError( contentHnd->errorString() );
- return FALSE;
+ return false;
}
// ... followed by endElement...
if ( !contentHnd->endElement( uri, lname, d->tags.pop() ) ) {
reportParseError( contentHnd->errorString() );
- return FALSE;
+ return false;
}
// ... followed by endPrefixMapping
TQStringList prefixesBefore, prefixesAfter;
@@ -3540,7 +3540,7 @@ bool TQXmlSimpleReader::processElementEmptyTag()
if ( prefixesAfter.contains(*it) == 0 ) {
if ( !contentHnd->endPrefixMapping( *it ) ) {
reportParseError( contentHnd->errorString() );
- return FALSE;
+ return false;
}
}
}
@@ -3548,23 +3548,23 @@ bool TQXmlSimpleReader::processElementEmptyTag()
// report startElement first...
if ( !contentHnd->startElement( TQString::null, TQString::null, d->tags.top(), d->attList ) ) {
reportParseError( contentHnd->errorString() );
- return FALSE;
+ return false;
}
// ... followed by endElement
if ( !contentHnd->endElement( TQString::null, TQString::null, d->tags.pop() ) ) {
reportParseError( contentHnd->errorString() );
- return FALSE;
+ return false;
}
}
} else {
d->tags.pop_back();
d->namespaceSupport.popContext();
}
- return TRUE;
+ return true;
}
/*
Helper to break down the size of the code in the case statement.
- Return FALSE on error, otherwise TRUE.
+ Return false on error, otherwise true.
*/
bool TQXmlSimpleReader::processElementETagBegin2()
{
@@ -3573,17 +3573,17 @@ bool TQXmlSimpleReader::processElementETagBegin2()
// pop the stack and compare it with the name
if ( d->tags.pop() != name ) {
reportParseError( XMLERR_TAGMISMATCH );
- return FALSE;
+ return false;
}
// call the handler
if ( contentHnd ) {
TQString uri, lname;
if (d->useNamespaces)
- d->namespaceSupport.processName(name, FALSE, uri, lname);
+ d->namespaceSupport.processName(name, false, uri, lname);
if (!contentHnd->endElement(uri, lname, name)) {
reportParseError(contentHnd->errorString());
- return FALSE;
+ return false;
}
}
if ( d->useNamespaces ) {
@@ -3600,18 +3600,18 @@ bool TQXmlSimpleReader::processElementETagBegin2()
if (!it.key().isEmpty() && !prefixesAfter.contains(it.key())) {
if (!contentHnd->endPrefixMapping(it.key())) {
reportParseError(contentHnd->errorString());
- return FALSE;
+ return false;
}
}
}
}
}
}
- return TRUE;
+ return true;
}
/*
Helper to break down the size of the code in the case statement.
- Return FALSE on error, otherwise TRUE.
+ Return false on error, otherwise true.
*/
bool TQXmlSimpleReader::processElementAttribute()
{
@@ -3636,19 +3636,19 @@ bool TQXmlSimpleReader::processElementAttribute()
if ( contentHnd ) {
if ( !contentHnd->startPrefixMapping( lname, string ) ) {
reportParseError( contentHnd->errorString() );
- return FALSE;
+ return false;
}
}
} else {
// no namespace delcaration
- d->namespaceSupport.processName( name, TRUE, uri, lname );
+ d->namespaceSupport.processName( name, true, uri, lname );
d->attList.append( name, uri, lname, string );
}
} else {
// no namespace support
d->attList.append( name, TQString::null, TQString::null, string );
}
- return TRUE;
+ return true;
}
/*
@@ -3729,7 +3729,7 @@ bool TQXmlSimpleReader::parseContent()
signed char input;
if ( d->parseStack==0 || d->parseStack->isEmpty() ) {
- d->contentCharDataRead = FALSE;
+ d->contentCharDataRead = false;
state = Init;
} else {
state = d->parseStack->pop().state;
@@ -3746,7 +3746,7 @@ bool TQXmlSimpleReader::parseContent()
}
if ( !(this->*function)() ) {
parseFailed( &TQXmlSimpleReader::parseContent, state );
- return FALSE;
+ return false;
}
}
}
@@ -3761,7 +3761,7 @@ bool TQXmlSimpleReader::parseContent()
if ( contentHnd ) {
if ( !contentHnd->processingInstruction(name(),string()) ) {
reportParseError( contentHnd->errorString() );
- return FALSE;
+ return false;
}
}
state = PInstrR;
@@ -3770,7 +3770,7 @@ bool TQXmlSimpleReader::parseContent()
if ( lexicalHnd ) {
if ( !lexicalHnd->comment( string() ) ) {
reportParseError( lexicalHnd->errorString() );
- return FALSE;
+ return false;
}
}
state = ComR;
@@ -3790,19 +3790,19 @@ bool TQXmlSimpleReader::parseContent()
if ( lexicalHnd ) {
if ( !lexicalHnd->startCDATA() ) {
reportParseError( lexicalHnd->errorString() );
- return FALSE;
+ return false;
}
}
if ( contentHnd ) {
if ( !contentHnd->characters( string() ) ) {
reportParseError( contentHnd->errorString() );
- return FALSE;
+ return false;
}
}
if ( lexicalHnd ) {
if ( !lexicalHnd->endCDATA() ) {
reportParseError( lexicalHnd->errorString() );
- return FALSE;
+ return false;
}
}
} else if (c.unicode() == ']') {
@@ -3822,24 +3822,24 @@ bool TQXmlSimpleReader::parseContent()
if ( d->reportWhitespaceCharData || !string().simplifyWhiteSpace().isEmpty() ) {
if ( !contentHnd->characters( string() ) ) {
reportParseError( contentHnd->errorString() );
- return FALSE;
+ return false;
}
}
}
}
// Done
- return TRUE;
+ return true;
case -1:
// Error
reportParseError( XMLERR_ERRORPARSINGCONTENT );
- return FALSE;
+ return false;
}
// get input (use lookup-table instead of nested ifs for performance
// reasons)
if ( atEnd() ) {
unexpectedEof( &TQXmlSimpleReader::parseContent, state );
- return FALSE;
+ return false;
}
if ( c.row() ) {
input = InpUnknown;
@@ -3856,26 +3856,26 @@ bool TQXmlSimpleReader::parseContent()
case ChD:
// on first call: clear string
if ( !d->contentCharDataRead ) {
- d->contentCharDataRead = TRUE;
+ d->contentCharDataRead = true;
stringClear();
}
stringAddC();
if ( d->reportEntities ) {
if ( !reportEndEntities() )
- return FALSE;
+ return false;
}
next();
break;
case ChD1:
// on first call: clear string
if ( !d->contentCharDataRead ) {
- d->contentCharDataRead = TRUE;
+ d->contentCharDataRead = true;
stringClear();
}
stringAddC();
if ( d->reportEntities ) {
if ( !reportEndEntities() )
- return FALSE;
+ return false;
}
next();
break;
@@ -3883,7 +3883,7 @@ bool TQXmlSimpleReader::parseContent()
stringAddC();
if ( d->reportEntities ) {
if ( !reportEndEntities() )
- return FALSE;
+ return false;
}
next();
break;
@@ -3894,7 +3894,7 @@ bool TQXmlSimpleReader::parseContent()
d->parseReference_context = InContent;
if ( !parseReference() ) {
parseFailed( &TQXmlSimpleReader::parseContent, state );
- return FALSE;
+ return false;
}
} else {
if ( d->reportEntities ) {
@@ -3903,7 +3903,7 @@ bool TQXmlSimpleReader::parseContent()
if ( d->reportWhitespaceCharData || !string().simplifyWhiteSpace().isEmpty() ) {
if ( !contentHnd->characters( string() ) ) {
reportParseError( contentHnd->errorString() );
- return FALSE;
+ return false;
}
}
}
@@ -3912,7 +3912,7 @@ bool TQXmlSimpleReader::parseContent()
d->parseReference_context = InContent;
if ( !parseReference() ) {
parseFailed( &TQXmlSimpleReader::parseContent, state );
- return FALSE;
+ return false;
}
}
break;
@@ -3923,26 +3923,26 @@ bool TQXmlSimpleReader::parseContent()
if ( d->reportWhitespaceCharData || !string().simplifyWhiteSpace().isEmpty() ) {
if ( !contentHnd->characters( string() ) ) {
reportParseError( contentHnd->errorString() );
- return FALSE;
+ return false;
}
}
}
}
- d->contentCharDataRead = FALSE;
+ d->contentCharDataRead = false;
next();
break;
case PInstr:
case PInstrR:
- d->parsePI_xmldecl = FALSE;
+ d->parsePI_xmldecl = false;
if ( !parsePI() ) {
parseFailed( &TQXmlSimpleReader::parseContent, state );
- return FALSE;
+ return false;
}
break;
case Elem:
if ( !parseElement() ) {
parseFailed( &TQXmlSimpleReader::parseContent, state );
- return FALSE;
+ return false;
}
break;
case Em:
@@ -3952,14 +3952,14 @@ bool TQXmlSimpleReader::parseContent()
case ComR:
if ( !parseComment() ) {
parseFailed( &TQXmlSimpleReader::parseContent, state );
- return FALSE;
+ return false;
}
break;
case CDS:
d->parseString_s = "[CDATA[";
if ( !parseString() ) {
parseFailed( &TQXmlSimpleReader::parseContent, state );
- return FALSE;
+ return false;
}
break;
case CDS1:
@@ -3985,7 +3985,7 @@ bool TQXmlSimpleReader::reportEndEntities()
if ( d->reportWhitespaceCharData || !string().simplifyWhiteSpace().isEmpty() ) {
if ( !contentHnd->characters( string() ) ) {
reportParseError( contentHnd->errorString() );
- return FALSE;
+ return false;
}
}
}
@@ -3993,14 +3993,14 @@ bool TQXmlSimpleReader::reportEndEntities()
if ( lexicalHnd ) {
if ( !lexicalHnd->endEntity(d->xmlRefName.top()) ) {
reportParseError( lexicalHnd->errorString() );
- return FALSE;
+ return false;
}
}
d->xmlRef.pop_back();
d->xmlRefName.pop_back();
count--;
}
- return TRUE;
+ return true;
}
/*
@@ -4047,7 +4047,7 @@ bool TQXmlSimpleReader::parseMisc()
}
if ( !(this->*function)() ) {
parseFailed( &TQXmlSimpleReader::parseMisc, state );
- return FALSE;
+ return false;
}
}
}
@@ -4055,32 +4055,32 @@ bool TQXmlSimpleReader::parseMisc()
for (;;) {
switch ( state ) {
case eatWS:
- return TRUE;
+ return true;
case PInstr:
if ( contentHnd ) {
if ( !contentHnd->processingInstruction(name(),string()) ) {
reportParseError( contentHnd->errorString() );
- return FALSE;
+ return false;
}
}
- return TRUE;
+ return true;
case Comment2:
if ( lexicalHnd ) {
if ( !lexicalHnd->comment( string() ) ) {
reportParseError( lexicalHnd->errorString() );
- return FALSE;
+ return false;
}
}
- return TRUE;
+ return true;
case -1:
// Error
reportParseError( XMLERR_UNEXPECTEDCHARACTER );
- return FALSE;
+ return false;
}
if ( atEnd() ) {
unexpectedEof( &TQXmlSimpleReader::parseMisc, state );
- return FALSE;
+ return false;
}
if ( is_S(c) ) {
input = InpWs;
@@ -4099,17 +4099,17 @@ bool TQXmlSimpleReader::parseMisc()
case eatWS:
if ( !eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseMisc, state );
- return FALSE;
+ return false;
}
break;
case Lt:
next();
break;
case PInstr:
- d->parsePI_xmldecl = FALSE;
+ d->parsePI_xmldecl = false;
if ( !parsePI() ) {
parseFailed( &TQXmlSimpleReader::parseMisc, state );
- return FALSE;
+ return false;
}
break;
case Comment:
@@ -4118,7 +4118,7 @@ bool TQXmlSimpleReader::parseMisc()
case Comment2:
if ( !parseComment() ) {
parseFailed( &TQXmlSimpleReader::parseMisc, state );
- return FALSE;
+ return false;
}
break;
}
@@ -4128,7 +4128,7 @@ bool TQXmlSimpleReader::parseMisc()
/*
Parse a processing instruction [16].
- If xmldec is TRUE, it tries to parse a PI or a XML declaration [23].
+ If xmldec is true, it tries to parse a PI or a XML declaration [23].
Precondition: the beginning '<' of the PI is already read and the head stand
on the '?' of '<?'.
@@ -4201,7 +4201,7 @@ bool TQXmlSimpleReader::parsePI()
}
if ( !(this->*function)() ) {
parseFailed( &TQXmlSimpleReader::parsePI, state );
- return FALSE;
+ return false;
}
}
}
@@ -4216,7 +4216,7 @@ bool TQXmlSimpleReader::parsePI()
state = XMLDecl;
} else {
reportParseError( XMLERR_INVALIDNAMEFORPI );
- return FALSE;
+ return false;
}
} else {
state = PInstr;
@@ -4227,7 +4227,7 @@ bool TQXmlSimpleReader::parsePI()
// get version (syntax like an attribute)
if ( name() != "version" ) {
reportParseError( XMLERR_VERSIONEXPECTED );
- return FALSE;
+ return false;
}
d->xmlVersion = string();
break;
@@ -4240,19 +4240,19 @@ bool TQXmlSimpleReader::parsePI()
d->standalone = TQXmlSimpleReaderPrivate::No;
} else {
reportParseError( XMLERR_WRONGVALUEFORSDECL );
- return FALSE;
+ return false;
}
} else if ( name() == "encoding" ) {
d->encoding = string();
} else {
reportParseError( XMLERR_EDECLORSDDECLEXPECTED );
- return FALSE;
+ return false;
}
break;
case SD:
if ( name() != "standalone" ) {
reportParseError( XMLERR_SDDECLEXPECTED );
- return FALSE;
+ return false;
}
if ( string()=="yes" ) {
d->standalone = TQXmlSimpleReaderPrivate::Yes;
@@ -4260,7 +4260,7 @@ bool TQXmlSimpleReader::parsePI()
d->standalone = TQXmlSimpleReaderPrivate::No;
} else {
reportParseError( XMLERR_WRONGVALUEFORSDECL );
- return FALSE;
+ return false;
}
break;
case Qm:
@@ -4269,16 +4269,16 @@ bool TQXmlSimpleReader::parsePI()
stringAddC( '?' );
break;
case Done:
- return TRUE;
+ return true;
case -1:
// Error
reportParseError( XMLERR_UNEXPECTEDCHARACTER );
- return FALSE;
+ return false;
}
if ( atEnd() ) {
unexpectedEof( &TQXmlSimpleReader::parsePI, state );
- return FALSE;
+ return false;
}
if ( is_S(c) ) {
input = InpWs;
@@ -4298,10 +4298,10 @@ bool TQXmlSimpleReader::parsePI()
next();
break;
case Name:
- d->parseName_useRef = FALSE;
+ d->parseName_useRef = false;
if ( !parseName() ) {
parseFailed( &TQXmlSimpleReader::parsePI, state );
- return FALSE;
+ return false;
}
break;
case Ws1:
@@ -4311,19 +4311,19 @@ bool TQXmlSimpleReader::parsePI()
case Ws5:
if ( !eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parsePI, state );
- return FALSE;
+ return false;
}
break;
case Version:
if ( !parseAttribute() ) {
parseFailed( &TQXmlSimpleReader::parsePI, state );
- return FALSE;
+ return false;
}
break;
case EorSD:
if ( !parseAttribute() ) {
parseFailed( &TQXmlSimpleReader::parsePI, state );
- return FALSE;
+ return false;
}
break;
case SD:
@@ -4331,11 +4331,11 @@ bool TQXmlSimpleReader::parsePI()
if ( d->standalone != TQXmlSimpleReaderPrivate::Unknown ) {
// already parsed the standalone declaration
reportParseError( XMLERR_UNEXPECTEDCHARACTER );
- return FALSE;
+ return false;
}
if ( !parseAttribute() ) {
parseFailed( &TQXmlSimpleReader::parsePI, state );
- return FALSE;
+ return false;
}
break;
case ADone:
@@ -4411,7 +4411,7 @@ bool TQXmlSimpleReader::parseDoctype()
signed char input;
if ( d->parseStack==0 || d->parseStack->isEmpty() ) {
- d->startDTDwasReported = FALSE;
+ d->startDTDwasReported = false;
d->systemId = TQString::null;
d->publicId = TQString::null;
state = Init;
@@ -4430,7 +4430,7 @@ bool TQXmlSimpleReader::parseDoctype()
}
if ( !(this->*function)() ) {
parseFailed( &TQXmlSimpleReader::parseDoctype, state );
- return FALSE;
+ return false;
}
}
}
@@ -4442,25 +4442,25 @@ bool TQXmlSimpleReader::parseDoctype()
break;
case MP:
if ( !d->startDTDwasReported && lexicalHnd ) {
- d->startDTDwasReported = TRUE;
+ d->startDTDwasReported = true;
if ( !lexicalHnd->startDTD( d->doctype, d->publicId, d->systemId ) ) {
reportParseError( lexicalHnd->errorString() );
- return FALSE;
+ return false;
}
}
state = MPR;
break;
case Done:
- return TRUE;
+ return true;
case -1:
// Error
reportParseError( XMLERR_ERRORPARSINGDOCTYPE );
- return FALSE;
+ return false;
}
if ( atEnd() ) {
unexpectedEof( &TQXmlSimpleReader::parseDoctype, state );
- return FALSE;
+ return false;
}
if ( is_S(c) ) {
input = InpWs;
@@ -4488,7 +4488,7 @@ bool TQXmlSimpleReader::parseDoctype()
d->parseString_s = "DOCTYPE";
if ( !parseString() ) {
parseFailed( &TQXmlSimpleReader::parseDoctype, state );
- return FALSE;
+ return false;
}
break;
case Ws1:
@@ -4497,66 +4497,66 @@ bool TQXmlSimpleReader::parseDoctype()
case Ws4:
if ( !eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseDoctype, state );
- return FALSE;
+ return false;
}
break;
case Doctype2:
- d->parseName_useRef = FALSE;
+ d->parseName_useRef = false;
if ( !parseName() ) {
parseFailed( &TQXmlSimpleReader::parseDoctype, state );
- return FALSE;
+ return false;
}
break;
case Sys:
- d->parseExternalID_allowPublicID = FALSE;
+ d->parseExternalID_allowPublicID = false;
if ( !parseExternalID() ) {
parseFailed( &TQXmlSimpleReader::parseDoctype, state );
- return FALSE;
+ return false;
}
break;
case MP:
case MPR:
if ( !next_eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseDoctype, state );
- return FALSE;
+ return false;
}
break;
case PER:
d->parsePEReference_context = InDTD;
if ( !parsePEReference() ) {
parseFailed( &TQXmlSimpleReader::parseDoctype, state );
- return FALSE;
+ return false;
}
break;
case Mup:
if (dtdRecursionLimit > 0U && d->parameterEntities.size() > dtdRecursionLimit) {
reportParseError(TQString::fromLatin1(
"DTD parsing exceeded recursion limit of %1.").arg(dtdRecursionLimit));
- return FALSE;
+ return false;
}
if ( !parseMarkupdecl() ) {
parseFailed( &TQXmlSimpleReader::parseDoctype, state );
- return FALSE;
+ return false;
}
break;
case MPE:
if ( !next_eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseDoctype, state );
- return FALSE;
+ return false;
}
break;
case Done:
if ( lexicalHnd ) {
if ( !d->startDTDwasReported ) {
- d->startDTDwasReported = TRUE;
+ d->startDTDwasReported = true;
if ( !lexicalHnd->startDTD( d->doctype, d->publicId, d->systemId ) ) {
reportParseError( lexicalHnd->errorString() );
- return FALSE;
+ return false;
}
}
if ( !lexicalHnd->endDTD() ) {
reportParseError( lexicalHnd->errorString() );
- return FALSE;
+ return false;
}
}
next();
@@ -4568,7 +4568,7 @@ bool TQXmlSimpleReader::parseDoctype()
/*
Parse a ExternalID [75].
- If allowPublicID is TRUE parse ExternalID [75] or PublicID [83].
+ If allowPublicID is true parse ExternalID [75] or PublicID [83].
*/
bool TQXmlSimpleReader::parseExternalID()
{
@@ -4587,7 +4587,7 @@ bool TQXmlSimpleReader::parseExternalID()
const signed char PubDQ2 = 12; // parse PubidLiteral with "
const signed char PubE = 13; // finished parsing the PubidLiteral
const signed char PubWS2 = 14; // parse the whitespace after the PubidLiteral
- const signed char PDone = 15; // done if allowPublicID is TRUE
+ const signed char PDone = 15; // done if allowPublicID is true
const signed char Done = 16;
const signed char InpSQ = 0; // '
@@ -4637,7 +4637,7 @@ bool TQXmlSimpleReader::parseExternalID()
}
if ( !(this->*function)() ) {
parseFailed( &TQXmlSimpleReader::parseExternalID, state );
- return FALSE;
+ return false;
}
}
}
@@ -4647,22 +4647,22 @@ bool TQXmlSimpleReader::parseExternalID()
case PDone:
if ( d->parseExternalID_allowPublicID ) {
d->publicId = string();
- return TRUE;
+ return true;
} else {
reportParseError( XMLERR_UNEXPECTEDCHARACTER );
- return FALSE;
+ return false;
}
case Done:
- return TRUE;
+ return true;
case -1:
// Error
reportParseError( XMLERR_UNEXPECTEDCHARACTER );
- return FALSE;
+ return false;
}
if ( atEnd() ) {
unexpectedEof( &TQXmlSimpleReader::parseExternalID, state );
- return FALSE;
+ return false;
}
if ( is_S(c) ) {
input = InpWs;
@@ -4684,13 +4684,13 @@ bool TQXmlSimpleReader::parseExternalID()
d->parseString_s = "SYSTEM";
if ( !parseString() ) {
parseFailed( &TQXmlSimpleReader::parseExternalID, state );
- return FALSE;
+ return false;
}
break;
case SysWS:
if ( !eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseExternalID, state );
- return FALSE;
+ return false;
}
break;
case SysSQ:
@@ -4707,13 +4707,13 @@ bool TQXmlSimpleReader::parseExternalID()
d->parseString_s = "PUBLIC";
if ( !parseString() ) {
parseFailed( &TQXmlSimpleReader::parseExternalID, state );
- return FALSE;
+ return false;
}
break;
case PubWS:
if ( !eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseExternalID, state );
- return FALSE;
+ return false;
}
break;
case PubSQ:
@@ -4733,7 +4733,7 @@ bool TQXmlSimpleReader::parseExternalID()
d->publicId = string();
if ( !eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseExternalID, state );
- return FALSE;
+ return false;
}
break;
case Done:
@@ -4798,7 +4798,7 @@ bool TQXmlSimpleReader::parseMarkupdecl()
}
if ( !(this->*function)() ) {
parseFailed( &TQXmlSimpleReader::parseMarkupdecl, state );
- return FALSE;
+ return false;
}
}
}
@@ -4809,37 +4809,37 @@ bool TQXmlSimpleReader::parseMarkupdecl()
if ( contentHnd ) {
if ( !contentHnd->processingInstruction(name(),string()) ) {
reportParseError( contentHnd->errorString() );
- return FALSE;
+ return false;
}
}
- return TRUE;
+ return true;
case Dash:
if ( lexicalHnd ) {
if ( !lexicalHnd->comment( string() ) ) {
reportParseError( lexicalHnd->errorString() );
- return FALSE;
+ return false;
}
}
- return TRUE;
+ return true;
case CA:
- return TRUE;
+ return true;
case CEL:
- return TRUE;
+ return true;
case CEN:
- return TRUE;
+ return true;
case CN:
- return TRUE;
+ return true;
case Done:
- return TRUE;
+ return true;
case -1:
// Error
reportParseError( XMLERR_LETTEREXPECTED );
- return FALSE;
+ return false;
}
if ( atEnd() ) {
unexpectedEof( &TQXmlSimpleReader::parseMarkupdecl, state );
- return FALSE;
+ return false;
}
if ( c.unicode() == '<' ) {
input = InpLt;
@@ -4873,40 +4873,40 @@ bool TQXmlSimpleReader::parseMarkupdecl()
next();
break;
case Qm:
- d->parsePI_xmldecl = FALSE;
+ d->parsePI_xmldecl = false;
if ( !parsePI() ) {
parseFailed( &TQXmlSimpleReader::parseMarkupdecl, state );
- return FALSE;
+ return false;
}
break;
case Dash:
if ( !parseComment() ) {
parseFailed( &TQXmlSimpleReader::parseMarkupdecl, state );
- return FALSE;
+ return false;
}
break;
case CA:
if ( !parseAttlistDecl() ) {
parseFailed( &TQXmlSimpleReader::parseMarkupdecl, state );
- return FALSE;
+ return false;
}
break;
case CEL:
if ( !parseElementDecl() ) {
parseFailed( &TQXmlSimpleReader::parseMarkupdecl, state );
- return FALSE;
+ return false;
}
break;
case CEN:
if ( !parseEntityDecl() ) {
parseFailed( &TQXmlSimpleReader::parseMarkupdecl, state );
- return FALSE;
+ return false;
}
break;
case CN:
if ( !parseNotationDecl() ) {
parseFailed( &TQXmlSimpleReader::parseMarkupdecl, state );
- return FALSE;
+ return false;
}
break;
}
@@ -4955,7 +4955,7 @@ bool TQXmlSimpleReader::parsePEReference()
}
if ( !(this->*function)() ) {
parseFailed( &TQXmlSimpleReader::parsePEReference, state );
- return FALSE;
+ return false;
}
}
}
@@ -4964,13 +4964,13 @@ bool TQXmlSimpleReader::parsePEReference()
switch ( state ) {
case Name:
{
- bool skipIt = TRUE;
+ bool skipIt = true;
TQString xmlRefString;
TQMap<TQString,TQString>::Iterator it;
it = d->parameterEntities.find( ref() );
if ( it != d->parameterEntities.end() ) {
- skipIt = FALSE;
+ skipIt = false;
xmlRefString = it.data();
} else if ( entityRes ) {
TQMap<TQString,TQXmlSimpleReaderPrivate::ExternParameterEntity>::Iterator it2;
@@ -4980,16 +4980,16 @@ bool TQXmlSimpleReader::parsePEReference()
if ( !entityRes->resolveEntity( it2.data().publicId, it2.data().systemId, ret ) ) {
delete ret;
reportParseError( entityRes->errorString() );
- return FALSE;
+ return false;
}
if ( ret ) {
xmlRefString = ret->data();
delete ret;
if ( !stripTextDecl( xmlRefString ) ) {
reportParseError( XMLERR_ERRORINTEXTDECL );
- return FALSE;
+ return false;
}
- skipIt = FALSE;
+ skipIt = false;
}
}
}
@@ -4998,34 +4998,34 @@ bool TQXmlSimpleReader::parsePEReference()
if ( contentHnd ) {
if ( !contentHnd->skippedEntity( TQString("%") + ref() ) ) {
reportParseError( contentHnd->errorString() );
- return FALSE;
+ return false;
}
}
} else {
if ( d->parsePEReference_context == InEntityValue ) {
// Included in literal
- if ( !insertXmlRef( xmlRefString, ref(), TRUE ) )
- return FALSE;
+ if ( !insertXmlRef( xmlRefString, ref(), true ) )
+ return false;
} else if ( d->parsePEReference_context == InDTD ) {
// Included as PE
- if ( !insertXmlRef( TQString(" ")+xmlRefString+TQString(" "), ref(), FALSE ) )
- return FALSE;
+ if ( !insertXmlRef( TQString(" ")+xmlRefString+TQString(" "), ref(), false ) )
+ return false;
}
}
}
state = NameR;
break;
case Done:
- return TRUE;
+ return true;
case -1:
// Error
reportParseError( XMLERR_LETTEREXPECTED );
- return FALSE;
+ return false;
}
if ( atEnd() ) {
unexpectedEof( &TQXmlSimpleReader::parsePEReference, state );
- return FALSE;
+ return false;
}
if ( c.unicode() == ';' ) {
input = InpSemi;
@@ -5042,10 +5042,10 @@ bool TQXmlSimpleReader::parsePEReference()
break;
case Name:
case NameR:
- d->parseName_useRef = TRUE;
+ d->parseName_useRef = true;
if ( !parseName() ) {
parseFailed( &TQXmlSimpleReader::parsePEReference, state );
- return FALSE;
+ return false;
}
break;
case Done:
@@ -5127,7 +5127,7 @@ bool TQXmlSimpleReader::parseAttlistDecl()
}
if ( !(this->*function)() ) {
parseFailed( &TQXmlSimpleReader::parseAttlistDecl, state );
- return FALSE;
+ return false;
}
}
}
@@ -5141,16 +5141,16 @@ bool TQXmlSimpleReader::parseAttlistDecl()
d->attDeclAName = name();
break;
case Done:
- return TRUE;
+ return true;
case -1:
// Error
reportParseError( XMLERR_LETTEREXPECTED );
- return FALSE;
+ return false;
}
if ( atEnd() ) {
unexpectedEof( &TQXmlSimpleReader::parseAttlistDecl, state );
- return FALSE;
+ return false;
}
if ( is_S(c) ) {
input = InpWs;
@@ -5176,7 +5176,7 @@ bool TQXmlSimpleReader::parseAttlistDecl()
d->parseString_s = "ATTLIST";
if ( !parseString() ) {
parseFailed( &TQXmlSimpleReader::parseAttlistDecl, state );
- return FALSE;
+ return false;
}
break;
case Ws:
@@ -5185,27 +5185,27 @@ bool TQXmlSimpleReader::parseAttlistDecl()
case Ws3:
if ( !eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseAttlistDecl, state );
- return FALSE;
+ return false;
}
break;
case Name:
- d->parseName_useRef = FALSE;
+ d->parseName_useRef = false;
if ( !parseName() ) {
parseFailed( &TQXmlSimpleReader::parseAttlistDecl, state );
- return FALSE;
+ return false;
}
break;
case Attdef:
- d->parseName_useRef = FALSE;
+ d->parseName_useRef = false;
if ( !parseName() ) {
parseFailed( &TQXmlSimpleReader::parseAttlistDecl, state );
- return FALSE;
+ return false;
}
break;
case Atttype:
if ( !parseAttType() ) {
parseFailed( &TQXmlSimpleReader::parseAttlistDecl, state );
- return FALSE;
+ return false;
}
break;
case DDecH:
@@ -5215,27 +5215,27 @@ bool TQXmlSimpleReader::parseAttlistDecl()
d->parseString_s = "REQUIRED";
if ( !parseString() ) {
parseFailed( &TQXmlSimpleReader::parseAttlistDecl, state );
- return FALSE;
+ return false;
}
break;
case DefImp:
d->parseString_s = "IMPLIED";
if ( !parseString() ) {
parseFailed( &TQXmlSimpleReader::parseAttlistDecl, state );
- return FALSE;
+ return false;
}
break;
case DefFix:
d->parseString_s = "FIXED";
if ( !parseString() ) {
parseFailed( &TQXmlSimpleReader::parseAttlistDecl, state );
- return FALSE;
+ return false;
}
break;
case Attval:
if ( !parseAttValue() ) {
parseFailed( &TQXmlSimpleReader::parseAttlistDecl, state );
- return FALSE;
+ return false;
}
break;
case Ws4:
@@ -5243,12 +5243,12 @@ bool TQXmlSimpleReader::parseAttlistDecl()
// ### not all values are computed yet...
if ( !declHnd->attributeDecl( d->attDeclEName, d->attDeclAName, "", "", "" ) ) {
reportParseError( declHnd->errorString() );
- return FALSE;
+ return false;
}
}
if ( !eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseAttlistDecl, state );
- return FALSE;
+ return false;
}
break;
case Done:
@@ -5342,7 +5342,7 @@ bool TQXmlSimpleReader::parseAttType()
}
if ( !(this->*function)() ) {
parseFailed( &TQXmlSimpleReader::parseAttType, state );
- return FALSE;
+ return false;
}
}
}
@@ -5350,18 +5350,18 @@ bool TQXmlSimpleReader::parseAttType()
for (;;) {
switch ( state ) {
case ADone:
- return TRUE;
+ return true;
case Done:
- return TRUE;
+ return true;
case -1:
// Error
reportParseError( XMLERR_LETTEREXPECTED );
- return FALSE;
+ return false;
}
if ( atEnd() ) {
unexpectedEof( &TQXmlSimpleReader::parseAttType, state );
- return FALSE;
+ return false;
}
if ( is_S(c) ) {
input = InpWs;
@@ -5399,21 +5399,21 @@ bool TQXmlSimpleReader::parseAttType()
d->parseString_s = "CDATA";
if ( !parseString() ) {
parseFailed( &TQXmlSimpleReader::parseAttType, state );
- return FALSE;
+ return false;
}
break;
case TTI:
d->parseString_s = "ID";
if ( !parseString() ) {
parseFailed( &TQXmlSimpleReader::parseAttType, state );
- return FALSE;
+ return false;
}
break;
case TTI2:
d->parseString_s = "REF";
if ( !parseString() ) {
parseFailed( &TQXmlSimpleReader::parseAttType, state );
- return FALSE;
+ return false;
}
break;
case TTI3:
@@ -5423,7 +5423,7 @@ bool TQXmlSimpleReader::parseAttType()
d->parseString_s = "ENTIT";
if ( !parseString() ) {
parseFailed( &TQXmlSimpleReader::parseAttType, state );
- return FALSE;
+ return false;
}
break;
case TTEY:
@@ -5433,7 +5433,7 @@ bool TQXmlSimpleReader::parseAttType()
d->parseString_s = "IES";
if ( !parseString() ) {
parseFailed( &TQXmlSimpleReader::parseAttType, state );
- return FALSE;
+ return false;
}
break;
case N:
@@ -5443,7 +5443,7 @@ bool TQXmlSimpleReader::parseAttType()
d->parseString_s = "MTOKEN";
if ( !parseString() ) {
parseFailed( &TQXmlSimpleReader::parseAttType, state );
- return FALSE;
+ return false;
}
break;
case TTNM2:
@@ -5453,50 +5453,50 @@ bool TQXmlSimpleReader::parseAttType()
d->parseString_s = "OTATION";
if ( !parseString() ) {
parseFailed( &TQXmlSimpleReader::parseAttType, state );
- return FALSE;
+ return false;
}
break;
case NO2:
if ( !eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseAttType, state );
- return FALSE;
+ return false;
}
break;
case NO3:
if ( !next_eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseAttType, state );
- return FALSE;
+ return false;
}
break;
case NOName:
- d->parseName_useRef = FALSE;
+ d->parseName_useRef = false;
if ( !parseName() ) {
parseFailed( &TQXmlSimpleReader::parseAttType, state );
- return FALSE;
+ return false;
}
break;
case NO4:
if ( !eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseAttType, state );
- return FALSE;
+ return false;
}
break;
case EN:
if ( !next_eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseAttType, state );
- return FALSE;
+ return false;
}
break;
case ENNmt:
if ( !parseNmtoken() ) {
parseFailed( &TQXmlSimpleReader::parseAttType, state );
- return FALSE;
+ return false;
}
break;
case EN2:
if ( !eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseAttType, state );
- return FALSE;
+ return false;
}
break;
case ADone:
@@ -5562,7 +5562,7 @@ bool TQXmlSimpleReader::parseAttValue()
}
if ( !(this->*function)() ) {
parseFailed( &TQXmlSimpleReader::parseAttValue, state );
- return FALSE;
+ return false;
}
}
}
@@ -5570,16 +5570,16 @@ bool TQXmlSimpleReader::parseAttValue()
for (;;) {
switch ( state ) {
case Done:
- return TRUE;
+ return true;
case -1:
// Error
reportParseError( XMLERR_UNEXPECTEDCHARACTER );
- return FALSE;
+ return false;
}
if ( atEnd() ) {
unexpectedEof( &TQXmlSimpleReader::parseAttValue, state );
- return FALSE;
+ return false;
}
if ( c.unicode() == '"' ) {
input = InpDq;
@@ -5605,7 +5605,7 @@ bool TQXmlSimpleReader::parseAttValue()
d->parseReference_context = InAttributeValue;
if ( !parseReference() ) {
parseFailed( &TQXmlSimpleReader::parseAttValue, state );
- return FALSE;
+ return false;
}
break;
case DqC:
@@ -5703,7 +5703,7 @@ bool TQXmlSimpleReader::parseElementDecl()
}
if ( !(this->*function)() ) {
parseFailed( &TQXmlSimpleReader::parseElementDecl, state );
- return FALSE;
+ return false;
}
}
}
@@ -5711,15 +5711,15 @@ bool TQXmlSimpleReader::parseElementDecl()
for (;;) {
switch ( state ) {
case Done:
- return TRUE;
+ return true;
case -1:
reportParseError( XMLERR_UNEXPECTEDCHARACTER );
- return FALSE;
+ return false;
}
if ( atEnd() ) {
unexpectedEof( &TQXmlSimpleReader::parseElementDecl, state );
- return FALSE;
+ return false;
}
if ( is_S(c) ) {
input = InpWs;
@@ -5755,59 +5755,59 @@ bool TQXmlSimpleReader::parseElementDecl()
d->parseString_s = "LEMENT";
if ( !parseString() ) {
parseFailed( &TQXmlSimpleReader::parseElementDecl, state );
- return FALSE;
+ return false;
}
break;
case Ws1:
if ( !eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseElementDecl, state );
- return FALSE;
+ return false;
}
break;
case Nam:
- d->parseName_useRef = FALSE;
+ d->parseName_useRef = false;
if ( !parseName() ) {
parseFailed( &TQXmlSimpleReader::parseElementDecl, state );
- return FALSE;
+ return false;
}
break;
case Ws2:
if ( !eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseElementDecl, state );
- return FALSE;
+ return false;
}
break;
case Empty:
d->parseString_s = "EMPTY";
if ( !parseString() ) {
parseFailed( &TQXmlSimpleReader::parseElementDecl, state );
- return FALSE;
+ return false;
}
break;
case Any:
d->parseString_s = "ANY";
if ( !parseString() ) {
parseFailed( &TQXmlSimpleReader::parseElementDecl, state );
- return FALSE;
+ return false;
}
break;
case Cont:
if ( !next_eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseElementDecl, state );
- return FALSE;
+ return false;
}
break;
case Mix:
d->parseString_s = "#PCDATA";
if ( !parseString() ) {
parseFailed( &TQXmlSimpleReader::parseElementDecl, state );
- return FALSE;
+ return false;
}
break;
case Mix2:
if ( !eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseElementDecl, state );
- return FALSE;
+ return false;
}
break;
case Mix3:
@@ -5816,20 +5816,20 @@ bool TQXmlSimpleReader::parseElementDecl()
case MixN1:
if ( !next_eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseElementDecl, state );
- return FALSE;
+ return false;
}
break;
case MixN2:
- d->parseName_useRef = FALSE;
+ d->parseName_useRef = false;
if ( !parseName() ) {
parseFailed( &TQXmlSimpleReader::parseElementDecl, state );
- return FALSE;
+ return false;
}
break;
case MixN3:
if ( !eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseElementDecl, state );
- return FALSE;
+ return false;
}
break;
case MixN4:
@@ -5838,7 +5838,7 @@ bool TQXmlSimpleReader::parseElementDecl()
case Cp:
if ( !parseChoiceSeq() ) {
parseFailed( &TQXmlSimpleReader::parseElementDecl, state );
- return FALSE;
+ return false;
}
break;
case Cp2:
@@ -5847,7 +5847,7 @@ bool TQXmlSimpleReader::parseElementDecl()
case WsD:
if ( !next_eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseElementDecl, state );
- return FALSE;
+ return false;
}
break;
case Done:
@@ -5911,7 +5911,7 @@ bool TQXmlSimpleReader::parseNotationDecl()
}
if ( !(this->*function)() ) {
parseFailed( &TQXmlSimpleReader::parseNotationDecl, state );
- return FALSE;
+ return false;
}
}
}
@@ -5923,22 +5923,22 @@ bool TQXmlSimpleReader::parseNotationDecl()
if ( dtdHnd ) {
if ( !dtdHnd->notationDecl( name(), d->publicId, d->systemId ) ) {
reportParseError( dtdHnd->errorString() );
- return FALSE;
+ return false;
}
}
state = ExtIDR;
break;
case Done:
- return TRUE;
+ return true;
case -1:
// Error
reportParseError( XMLERR_UNEXPECTEDCHARACTER );
- return FALSE;
+ return false;
}
if ( atEnd() ) {
unexpectedEof( &TQXmlSimpleReader::parseNotationDecl, state );
- return FALSE;
+ return false;
}
if ( is_S(c) ) {
input = InpWs;
@@ -5956,40 +5956,40 @@ bool TQXmlSimpleReader::parseNotationDecl()
d->parseString_s = "NOTATION";
if ( !parseString() ) {
parseFailed( &TQXmlSimpleReader::parseNotationDecl, state );
- return FALSE;
+ return false;
}
break;
case Ws1:
if ( !eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseNotationDecl, state );
- return FALSE;
+ return false;
}
break;
case Nam:
- d->parseName_useRef = FALSE;
+ d->parseName_useRef = false;
if ( !parseName() ) {
parseFailed( &TQXmlSimpleReader::parseNotationDecl, state );
- return FALSE;
+ return false;
}
break;
case Ws2:
if ( !eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseNotationDecl, state );
- return FALSE;
+ return false;
}
break;
case ExtID:
case ExtIDR:
- d->parseExternalID_allowPublicID = TRUE;
+ d->parseExternalID_allowPublicID = true;
if ( !parseExternalID() ) {
parseFailed( &TQXmlSimpleReader::parseNotationDecl, state );
- return FALSE;
+ return false;
}
break;
case Ws3:
if ( !eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseNotationDecl, state );
- return FALSE;
+ return false;
}
break;
case Done:
@@ -6054,7 +6054,7 @@ bool TQXmlSimpleReader::parseChoiceSeq()
}
if ( !(this->*function)() ) {
parseFailed( &TQXmlSimpleReader::parseChoiceSeq, state );
- return FALSE;
+ return false;
}
}
}
@@ -6062,16 +6062,16 @@ bool TQXmlSimpleReader::parseChoiceSeq()
for (;;) {
switch ( state ) {
case Done:
- return TRUE;
+ return true;
case -1:
// Error
reportParseError( XMLERR_UNEXPECTEDCHARACTER );
- return FALSE;
+ return false;
}
if ( atEnd() ) {
unexpectedEof( &TQXmlSimpleReader::parseChoiceSeq, state );
- return FALSE;
+ return false;
}
if ( is_S(c) ) {
input = InpWs;
@@ -6098,32 +6098,32 @@ bool TQXmlSimpleReader::parseChoiceSeq()
case Ws1:
if ( !next_eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseChoiceSeq, state );
- return FALSE;
+ return false;
}
break;
case CorS:
if ( !parseChoiceSeq() ) {
parseFailed( &TQXmlSimpleReader::parseChoiceSeq, state );
- return FALSE;
+ return false;
}
break;
case Ws2:
if ( !next_eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseChoiceSeq, state );
- return FALSE;
+ return false;
}
break;
case More:
if ( !next_eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseChoiceSeq, state );
- return FALSE;
+ return false;
}
break;
case Name:
- d->parseName_useRef = FALSE;
+ d->parseName_useRef = false;
if ( !parseName() ) {
parseFailed( &TQXmlSimpleReader::parseChoiceSeq, state );
- return FALSE;
+ return false;
}
break;
case Done:
@@ -6179,10 +6179,10 @@ bool TQXmlSimpleReader::isExpandedEntityValueTooLarge(TQString *errorMessage)
*errorMessage = TQString::fromLatin1("The XML entity \"%1\" expands to a string that is too large to process (%2 characters > %3).");
*errorMessage = (*errorMessage).arg(entity).arg(expandedSizes[entity]).arg(entityCharacterLimit);
}
- return TRUE;
+ return true;
}
}
- return FALSE;
+ return false;
}
/*
@@ -6270,7 +6270,7 @@ bool TQXmlSimpleReader::parseEntityDecl()
}
if ( !(this->*function)() ) {
parseFailed( &TQXmlSimpleReader::parseEntityDecl, state );
- return FALSE;
+ return false;
}
}
}
@@ -6282,14 +6282,14 @@ bool TQXmlSimpleReader::parseEntityDecl()
TQString errorMessage;
if (isExpandedEntityValueTooLarge(&errorMessage)) {
reportParseError(errorMessage);
- return FALSE;
+ return false;
}
d->entities.insert( name(), string() );
if ( declHnd ) {
if ( !declHnd->internalEntityDecl( name(), string() ) ) {
reportParseError( declHnd->errorString() );
- return FALSE;
+ return false;
}
}
}
@@ -6301,7 +6301,7 @@ bool TQXmlSimpleReader::parseEntityDecl()
if ( dtdHnd ) {
if ( !dtdHnd->unparsedEntityDecl( name(), d->publicId, d->systemId, ref() ) ) {
reportParseError( declHnd->errorString() );
- return FALSE;
+ return false;
}
}
}
@@ -6313,7 +6313,7 @@ bool TQXmlSimpleReader::parseEntityDecl()
if ( declHnd ) {
if ( !declHnd->internalEntityDecl( TQString("%")+name(), string() ) ) {
reportParseError( declHnd->errorString() );
- return FALSE;
+ return false;
}
}
}
@@ -6325,7 +6325,7 @@ bool TQXmlSimpleReader::parseEntityDecl()
if ( declHnd ) {
if ( !declHnd->externalEntityDecl( TQString("%")+name(), d->publicId, d->systemId ) ) {
reportParseError( declHnd->errorString() );
- return FALSE;
+ return false;
}
}
}
@@ -6337,22 +6337,22 @@ bool TQXmlSimpleReader::parseEntityDecl()
if ( declHnd ) {
if ( !declHnd->externalEntityDecl( name(), d->publicId, d->systemId ) ) {
reportParseError( declHnd->errorString() );
- return FALSE;
+ return false;
}
}
}
- return TRUE;
+ return true;
case Done:
- return TRUE;
+ return true;
case -1:
// Error
reportParseError( XMLERR_LETTEREXPECTED );
- return FALSE;
+ return false;
}
if ( atEnd() ) {
unexpectedEof( &TQXmlSimpleReader::parseEntityDecl, state );
- return FALSE;
+ return false;
}
if ( is_S(c) ) {
input = InpWs;
@@ -6374,67 +6374,67 @@ bool TQXmlSimpleReader::parseEntityDecl()
d->parseString_s = "NTITY";
if ( !parseString() ) {
parseFailed( &TQXmlSimpleReader::parseEntityDecl, state );
- return FALSE;
+ return false;
}
break;
case Ws1:
if ( !eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseEntityDecl, state );
- return FALSE;
+ return false;
}
break;
case Name:
- d->parseName_useRef = FALSE;
+ d->parseName_useRef = false;
if ( !parseName() ) {
parseFailed( &TQXmlSimpleReader::parseEntityDecl, state );
- return FALSE;
+ return false;
}
break;
case Ws2:
if ( !eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseEntityDecl, state );
- return FALSE;
+ return false;
}
break;
case EValue:
case EValueR:
if ( !parseEntityValue() ) {
parseFailed( &TQXmlSimpleReader::parseEntityDecl, state );
- return FALSE;
+ return false;
}
break;
case ExtID:
- d->parseExternalID_allowPublicID = FALSE;
+ d->parseExternalID_allowPublicID = false;
if ( !parseExternalID() ) {
parseFailed( &TQXmlSimpleReader::parseEntityDecl, state );
- return FALSE;
+ return false;
}
break;
case Ws3:
if ( !eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseEntityDecl, state );
- return FALSE;
+ return false;
}
break;
case Ndata:
d->parseString_s = "NDATA";
if ( !parseString() ) {
parseFailed( &TQXmlSimpleReader::parseEntityDecl, state );
- return FALSE;
+ return false;
}
break;
case Ws4:
if ( !eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseEntityDecl, state );
- return FALSE;
+ return false;
}
break;
case NNam:
case NNamR:
- d->parseName_useRef = TRUE;
+ d->parseName_useRef = true;
if ( !parseName() ) {
parseFailed( &TQXmlSimpleReader::parseEntityDecl, state );
- return FALSE;
+ return false;
}
break;
case PEDec:
@@ -6443,41 +6443,41 @@ bool TQXmlSimpleReader::parseEntityDecl()
case Ws6:
if ( !eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseEntityDecl, state );
- return FALSE;
+ return false;
}
break;
case PENam:
- d->parseName_useRef = FALSE;
+ d->parseName_useRef = false;
if ( !parseName() ) {
parseFailed( &TQXmlSimpleReader::parseEntityDecl, state );
- return FALSE;
+ return false;
}
break;
case Ws7:
if ( !eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseEntityDecl, state );
- return FALSE;
+ return false;
}
break;
case PEVal:
case PEValR:
if ( !parseEntityValue() ) {
parseFailed( &TQXmlSimpleReader::parseEntityDecl, state );
- return FALSE;
+ return false;
}
break;
case PEEID:
case PEEIDR:
- d->parseExternalID_allowPublicID = FALSE;
+ d->parseExternalID_allowPublicID = false;
if ( !parseExternalID() ) {
parseFailed( &TQXmlSimpleReader::parseEntityDecl, state );
- return FALSE;
+ return false;
}
break;
case WsE:
if ( !eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseEntityDecl, state );
- return FALSE;
+ return false;
}
break;
case EDDone:
@@ -6544,7 +6544,7 @@ bool TQXmlSimpleReader::parseEntityValue()
}
if ( !(this->*function)() ) {
parseFailed( &TQXmlSimpleReader::parseEntityValue, state );
- return FALSE;
+ return false;
}
}
}
@@ -6552,16 +6552,16 @@ bool TQXmlSimpleReader::parseEntityValue()
for (;;) {
switch ( state ) {
case Done:
- return TRUE;
+ return true;
case -1:
// Error
reportParseError( XMLERR_LETTEREXPECTED );
- return FALSE;
+ return false;
}
if ( atEnd() ) {
unexpectedEof( &TQXmlSimpleReader::parseEntityValue, state );
- return FALSE;
+ return false;
}
if ( c.unicode() == '"' ) {
input = InpDq;
@@ -6592,7 +6592,7 @@ bool TQXmlSimpleReader::parseEntityValue()
d->parsePEReference_context = InEntityValue;
if ( !parsePEReference() ) {
parseFailed( &TQXmlSimpleReader::parseEntityValue, state );
- return FALSE;
+ return false;
}
break;
case DqRef:
@@ -6600,7 +6600,7 @@ bool TQXmlSimpleReader::parseEntityValue()
d->parseReference_context = InEntityValue;
if ( !parseReference() ) {
parseFailed( &TQXmlSimpleReader::parseEntityValue, state );
- return FALSE;
+ return false;
}
break;
case Done:
@@ -6662,7 +6662,7 @@ bool TQXmlSimpleReader::parseComment()
}
if ( !(this->*function)() ) {
parseFailed( &TQXmlSimpleReader::parseComment, state );
- return FALSE;
+ return false;
}
}
}
@@ -6678,16 +6678,16 @@ bool TQXmlSimpleReader::parseComment()
stringAddC( '-' );
break;
case Done:
- return TRUE;
+ return true;
case -1:
// Error
reportParseError( XMLERR_ERRORPARSINGCOMMENT );
- return FALSE;
+ return false;
}
if ( atEnd() ) {
unexpectedEof( &TQXmlSimpleReader::parseComment, state );
- return FALSE;
+ return false;
}
if ( c.unicode() == '-' ) {
input = InpDash;
@@ -6773,7 +6773,7 @@ bool TQXmlSimpleReader::parseAttribute()
}
if ( !(this->*function)() ) {
parseFailed( &TQXmlSimpleReader::parseAttribute, state );
- return FALSE;
+ return false;
}
}
}
@@ -6782,16 +6782,16 @@ bool TQXmlSimpleReader::parseAttribute()
switch ( state ) {
case Quotes:
// Done
- return TRUE;
+ return true;
case -1:
// Error
reportParseError( XMLERR_UNEXPECTEDCHARACTER );
- return FALSE;
+ return false;
}
if ( atEnd() ) {
unexpectedEof( &TQXmlSimpleReader::parseAttribute, state );
- return FALSE;
+ return false;
}
if ( determineNameChar(c) == NameBeginning ) {
input = InpNameBe;
@@ -6808,28 +6808,28 @@ bool TQXmlSimpleReader::parseAttribute()
switch ( state ) {
case PName:
- d->parseName_useRef = FALSE;
+ d->parseName_useRef = false;
if ( !parseName() ) {
parseFailed( &TQXmlSimpleReader::parseAttribute, state );
- return FALSE;
+ return false;
}
break;
case Ws:
if ( !eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseAttribute, state );
- return FALSE;
+ return false;
}
break;
case Eq:
if ( !next_eat_ws() ) {
parseFailed( &TQXmlSimpleReader::parseAttribute, state );
- return FALSE;
+ return false;
}
break;
case Quotes:
if ( !parseAttValue() ) {
parseFailed( &TQXmlSimpleReader::parseAttribute, state );
- return FALSE;
+ return false;
}
break;
}
@@ -6837,7 +6837,7 @@ bool TQXmlSimpleReader::parseAttribute()
}
/*
- Parse a Name [5] and store the name in name or ref (if useRef is TRUE).
+ Parse a Name [5] and store the name in name or ref (if useRef is true).
*/
bool TQXmlSimpleReader::parseName()
{
@@ -6879,7 +6879,7 @@ bool TQXmlSimpleReader::parseName()
}
if ( !(this->*function)() ) {
parseFailed( &TQXmlSimpleReader::parseName, state );
- return FALSE;
+ return false;
}
}
}
@@ -6887,16 +6887,16 @@ bool TQXmlSimpleReader::parseName()
for (;;) {
switch ( state ) {
case Done:
- return TRUE;
+ return true;
case -1:
// Error
reportParseError( XMLERR_LETTEREXPECTED );
- return FALSE;
+ return false;
}
if ( atEnd() ) {
unexpectedEof( &TQXmlSimpleReader::parseName, state );
- return FALSE;
+ return false;
}
// we can safely do the (int) cast thanks to the Q_ASSERTs earlier in this function
@@ -6964,7 +6964,7 @@ bool TQXmlSimpleReader::parseNmtoken()
}
if ( !(this->*function)() ) {
parseFailed( &TQXmlSimpleReader::parseNmtoken, state );
- return FALSE;
+ return false;
}
}
}
@@ -6972,16 +6972,16 @@ bool TQXmlSimpleReader::parseNmtoken()
for (;;) {
switch ( state ) {
case Done:
- return TRUE;
+ return true;
case -1:
// Error
reportParseError( XMLERR_LETTEREXPECTED );
- return FALSE;
+ return false;
}
if ( atEnd() ) {
unexpectedEof( &TQXmlSimpleReader::parseNmtoken, state );
- return FALSE;
+ return false;
}
if (determineNameChar(c) == NotName) {
input = InpUnknown;
@@ -7007,11 +7007,11 @@ bool TQXmlSimpleReader::parseNmtoken()
/*
Parse a Reference [67].
- parseReference_charDataRead is set to TRUE if the reference must not be
+ parseReference_charDataRead is set to true if the reference must not be
parsed. The character(s) which the reference mapped to are appended to
string. The head stands on the first character after the reference.
- parseReference_charDataRead is set to FALSE if the reference must be parsed.
+ parseReference_charDataRead is set to false if the reference must be parsed.
The charachter(s) which the reference mapped to are inserted at the reference
position. The head stands on the first character of the replacement).
*/
@@ -7055,7 +7055,7 @@ bool TQXmlSimpleReader::parseReference()
signed char input;
if ( d->parseStack==0 || d->parseStack->isEmpty() ) {
- d->parseReference_charDataRead = FALSE;
+ d->parseReference_charDataRead = false;
state = Init;
} else {
state = d->parseStack->pop().state;
@@ -7072,7 +7072,7 @@ bool TQXmlSimpleReader::parseReference()
}
if ( !(this->*function)() ) {
parseFailed( &TQXmlSimpleReader::parseReference, state );
- return FALSE;
+ return false;
}
}
}
@@ -7080,20 +7080,20 @@ bool TQXmlSimpleReader::parseReference()
for (;;) {
switch ( state ) {
case DoneD:
- return TRUE;
+ return true;
case DoneH:
- return TRUE;
+ return true;
case DoneN:
- return TRUE;
+ return true;
case -1:
// Error
reportParseError( XMLERR_ERRORPARSINGREFERENCE );
- return FALSE;
+ return false;
}
if ( atEnd() ) {
unexpectedEof( &TQXmlSimpleReader::parseReference, state );
- return FALSE;
+ return false;
}
if ( c.row() ) {
input = InpUnknown;
@@ -7137,10 +7137,10 @@ bool TQXmlSimpleReader::parseReference()
break;
case Name:
// read the name into the ref
- d->parseName_useRef = TRUE;
+ d->parseName_useRef = true;
if ( !parseName() ) {
parseFailed( &TQXmlSimpleReader::parseReference, state );
- return FALSE;
+ return false;
}
break;
case DoneD:
@@ -7149,9 +7149,9 @@ bool TQXmlSimpleReader::parseReference()
stringAddC( TQChar(tmp) );
} else {
reportParseError( XMLERR_ERRORPARSINGREFERENCE );
- return FALSE;
+ return false;
}
- d->parseReference_charDataRead = TRUE;
+ d->parseReference_charDataRead = true;
next();
break;
case DoneH:
@@ -7160,14 +7160,14 @@ bool TQXmlSimpleReader::parseReference()
stringAddC( TQChar(tmp) );
} else {
reportParseError( XMLERR_ERRORPARSINGREFERENCE );
- return FALSE;
+ return false;
}
- d->parseReference_charDataRead = TRUE;
+ d->parseReference_charDataRead = true;
next();
break;
case DoneN:
if ( !processReference() )
- return FALSE;
+ return false;
next();
break;
}
@@ -7202,7 +7202,7 @@ bool TQXmlSimpleReader::processReference()
// Included or Included in literal
stringAddC( '&' );
}
- d->parseReference_charDataRead = TRUE;
+ d->parseReference_charDataRead = true;
} else if ( reference == "lt" ) {
if ( d->parseReference_context == InEntityValue ) {
// Bypassed
@@ -7211,7 +7211,7 @@ bool TQXmlSimpleReader::processReference()
// Included or Included in literal
stringAddC( '<' );
}
- d->parseReference_charDataRead = TRUE;
+ d->parseReference_charDataRead = true;
} else if ( reference == "gt" ) {
if ( d->parseReference_context == InEntityValue ) {
// Bypassed
@@ -7220,7 +7220,7 @@ bool TQXmlSimpleReader::processReference()
// Included or Included in literal
stringAddC( '>' );
}
- d->parseReference_charDataRead = TRUE;
+ d->parseReference_charDataRead = true;
} else if ( reference == "apos" ) {
if ( d->parseReference_context == InEntityValue ) {
// Bypassed
@@ -7229,7 +7229,7 @@ bool TQXmlSimpleReader::processReference()
// Included or Included in literal
stringAddC( '\'' );
}
- d->parseReference_charDataRead = TRUE;
+ d->parseReference_charDataRead = true;
} else if ( reference == "quot" ) {
if ( d->parseReference_context == InEntityValue ) {
// Bypassed
@@ -7238,7 +7238,7 @@ bool TQXmlSimpleReader::processReference()
// Included or Included in literal
stringAddC( '"' );
}
- d->parseReference_charDataRead = TRUE;
+ d->parseReference_charDataRead = true;
} else {
TQMap<TQString,TQString>::Iterator it;
it = d->entities.find( reference );
@@ -7247,15 +7247,15 @@ bool TQXmlSimpleReader::processReference()
switch ( d->parseReference_context ) {
case InContent:
// Included
- if ( !insertXmlRef( it.data(), reference, FALSE ) )
- return FALSE;
- d->parseReference_charDataRead = FALSE;
+ if ( !insertXmlRef( it.data(), reference, false ) )
+ return false;
+ d->parseReference_charDataRead = false;
break;
case InAttributeValue:
// Included in literal
- if ( !insertXmlRef( it.data(), reference, TRUE ) )
- return FALSE;
- d->parseReference_charDataRead = FALSE;
+ if ( !insertXmlRef( it.data(), reference, true ) )
+ return false;
+ d->parseReference_charDataRead = false;
break;
case InEntityValue:
{
@@ -7265,14 +7265,14 @@ bool TQXmlSimpleReader::processReference()
stringAddC( reference[i] );
}
stringAddC( ';');
- d->parseReference_charDataRead = TRUE;
+ d->parseReference_charDataRead = true;
}
break;
case InDTD:
// Forbidden
- d->parseReference_charDataRead = FALSE;
+ d->parseReference_charDataRead = false;
reportParseError( XMLERR_INTERNALGENERALENTITYINDTD );
- return FALSE;
+ return false;
}
} else {
TQMap<TQString,TQXmlSimpleReaderPrivate::ExternEntity>::Iterator itExtern;
@@ -7287,13 +7287,13 @@ bool TQXmlSimpleReader::processReference()
stringAddC( reference[i] );
}
stringAddC( ';');
- d->parseReference_charDataRead = TRUE;
+ d->parseReference_charDataRead = true;
} else {
if ( contentHnd && !(d->parseReference_context == InAttributeValue
&& d->undefEntityInAttrHack)) {
if ( !contentHnd->skippedEntity( reference ) ) {
reportParseError( contentHnd->errorString() );
- return FALSE; // error
+ return false; // error
}
}
}
@@ -7303,39 +7303,39 @@ bool TQXmlSimpleReader::processReference()
case InContent:
{
// Included if validating
- bool skipIt = TRUE;
+ bool skipIt = true;
if ( entityRes ) {
TQXmlInputSource *ret = 0;
if ( !entityRes->resolveEntity( itExtern.data().publicId, itExtern.data().systemId, ret ) ) {
delete ret;
reportParseError( entityRes->errorString() );
- return FALSE;
+ return false;
}
if ( ret ) {
TQString xmlRefString = ret->data();
delete ret;
if ( !stripTextDecl( xmlRefString ) ) {
reportParseError( XMLERR_ERRORINTEXTDECL );
- return FALSE;
+ return false;
}
- if ( !insertXmlRef( xmlRefString, reference, FALSE ) )
- return FALSE;
- skipIt = FALSE;
+ if ( !insertXmlRef( xmlRefString, reference, false ) )
+ return false;
+ skipIt = false;
}
}
if ( skipIt && contentHnd ) {
if ( !contentHnd->skippedEntity( reference ) ) {
reportParseError( contentHnd->errorString() );
- return FALSE; // error
+ return false; // error
}
}
- d->parseReference_charDataRead = FALSE;
+ d->parseReference_charDataRead = false;
} break;
case InAttributeValue:
// Forbidden
- d->parseReference_charDataRead = FALSE;
+ d->parseReference_charDataRead = false;
reportParseError( XMLERR_EXTERNALGENERALENTITYINAV );
- return FALSE;
+ return false;
case InEntityValue:
{
// Bypassed
@@ -7344,26 +7344,26 @@ bool TQXmlSimpleReader::processReference()
stringAddC( reference[i] );
}
stringAddC( ';');
- d->parseReference_charDataRead = TRUE;
+ d->parseReference_charDataRead = true;
}
break;
case InDTD:
// Forbidden
- d->parseReference_charDataRead = FALSE;
+ d->parseReference_charDataRead = false;
reportParseError( XMLERR_EXTERNALGENERALENTITYINDTD );
- return FALSE;
+ return false;
}
} else {
// "Unparsed"
// ### notify for "Occurs as Attribute Value" missing (but this is no refence, anyway)
// Forbidden
- d->parseReference_charDataRead = FALSE;
+ d->parseReference_charDataRead = false;
reportParseError( XMLERR_UNPARSEDENTITYREFERENCE );
- return FALSE; // error
+ return false; // error
}
}
}
- return TRUE; // no error
+ return true; // no error
}
@@ -7399,19 +7399,19 @@ bool TQXmlSimpleReader::parseString()
}
if ( !(this->*function)() ) {
parseFailed( &TQXmlSimpleReader::parseString, state );
- return FALSE;
+ return false;
}
}
}
for (;;) {
if ( state == d->Done ) {
- return TRUE;
+ return true;
}
if ( atEnd() ) {
unexpectedEof( &TQXmlSimpleReader::parseString, state );
- return FALSE;
+ return false;
}
if ( c == d->parseString_s[(int)state] ) {
input = InpCharExpected;
@@ -7423,7 +7423,7 @@ bool TQXmlSimpleReader::parseString()
} else {
// Error
reportParseError( XMLERR_UNEXPECTEDCHARACTER );
- return FALSE;
+ return false;
}
next();
@@ -7433,10 +7433,10 @@ bool TQXmlSimpleReader::parseString()
/*
This private function inserts and reports an entity substitution. The
substituted string is \a data and the name of the entity reference is \a
- name. If \a inLiteral is TRUE, the entity is IncludedInLiteral (i.e., " and '
+ name. If \a inLiteral is true, the entity is IncludedInLiteral (i.e., " and '
must be quoted. Otherwise they are not quoted.
- This function returns FALSE on error.
+ This function returns false on error.
*/
bool TQXmlSimpleReader::insertXmlRef( const TQString &data, const TQString &name, bool inLiteral )
{
@@ -7451,15 +7451,15 @@ bool TQXmlSimpleReader::insertXmlRef( const TQString &data, const TQString &name
if ( d->xmlRefName.count() > n+1 ) {
// recursive entities
reportParseError( XMLERR_RECURSIVEENTITIES );
- return FALSE;
+ return false;
}
if ( d->reportEntities && lexicalHnd ) {
if ( !lexicalHnd->startEntity( name ) ) {
reportParseError( lexicalHnd->errorString() );
- return FALSE;
+ return false;
}
}
- return TRUE;
+ return true;
}
/*
@@ -7503,24 +7503,24 @@ void TQXmlSimpleReader::next()
This function does not move the cursor if the actual cursor position is a
non-whitespace charcter.
- Returns FALSE when you use incremental parsing and this function reaches EOF
+ Returns false when you use incremental parsing and this function reaches EOF
with reading only whitespace characters. In this case it also poplulates the
parseStack with useful information. In all other cases, this function returns
- TRUE.
+ true.
*/
bool TQXmlSimpleReader::eat_ws()
{
while ( !atEnd() ) {
if ( !is_S(c) ) {
- return TRUE;
+ return true;
}
next();
}
if ( d->parseStack != 0 ) {
unexpectedEof( &TQXmlSimpleReader::eat_ws, 0 );
- return FALSE;
+ return false;
}
- return TRUE;
+ return true;
}
bool TQXmlSimpleReader::next_eat_ws()
@@ -7567,8 +7567,8 @@ void TQXmlSimpleReader::initData()
}
/*
- Returns TRUE if a entity with the name \a e exists,
- otherwise returns FALSE.
+ Returns true if a entity with the name \a e exists,
+ otherwise returns false.
*/
bool TQXmlSimpleReader::entityExist( const TQString& e ) const
{
@@ -7576,9 +7576,9 @@ bool TQXmlSimpleReader::entityExist( const TQString& e ) const
d->externParameterEntities.find(e) == d->externParameterEntities.end() &&
d->externEntities.find(e) == d->externEntities.end() &&
d->entities.find(e) == d->entities.end() ) {
- return FALSE;
+ return false;
} else {
- return TRUE;
+ return true;
}
}
@@ -7614,7 +7614,7 @@ void TQXmlSimpleReader::unexpectedEof( ParseFunction where, int state )
}
/*
- This private function is called when a parse...() function returned FALSE. It
+ This private function is called when a parse...() function returned false. It
determines if there was an error or if incremental parsing simply went out of
data and does the right thing for the case. \a where is a pointer to the
function where the error occurred and \a state is the parsing state in this