diff options
author | kitty <kitty@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2002-08-22 01:51:15 +0000 |
---|---|---|
committer | kitty <kitty@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2002-08-22 01:51:15 +0000 |
commit | 277385e3ab1d37fe5def730908c469758a40ea21 (patch) | |
tree | 8292467ba1f6c5fb9eddd6b55f922c8c29797356 /ACEXML | |
parent | 54078a090cdb23757844231f3260fdbf70c58252 (diff) | |
download | ATCD-277385e3ab1d37fe5def730908c469758a40ea21.tar.gz |
ChangeLogTag: Wed Aug 21 20:40:20 2002 Krishnakumar B <kitty@cs.wustl.edu>
Diffstat (limited to 'ACEXML')
-rw-r--r-- | ACEXML/apps/svcconf/Svcconf_Handler.cpp | 12 | ||||
-rw-r--r-- | ACEXML/apps/svcconf/Svcconf_Handler.h | 2 | ||||
-rw-r--r-- | ACEXML/common/FileCharStream.cpp | 12 | ||||
-rw-r--r-- | ACEXML/common/HttpCharStream.cpp | 4 | ||||
-rw-r--r-- | ACEXML/common/XMLFilterImpl.cpp | 4 | ||||
-rw-r--r-- | ACEXML/examples/SAXPrint/Print_Handler.cpp | 42 | ||||
-rw-r--r-- | ACEXML/examples/SAXPrint/SAXPrint_Handler.cpp | 32 | ||||
-rw-r--r-- | ACEXML/examples/SAXPrint/main.cpp | 7 | ||||
-rw-r--r-- | ACEXML/examples/svcconf/Svcconf_Handler.cpp | 4 | ||||
-rw-r--r-- | ACEXML/parser/debug_validator/Debug_Attributes_Builder.cpp | 4 | ||||
-rw-r--r-- | ACEXML/parser/debug_validator/Debug_DTD_Manager.cpp | 4 | ||||
-rw-r--r-- | ACEXML/parser/debug_validator/Debug_Element_Builder.cpp | 2 | ||||
-rw-r--r-- | ACEXML/parser/debug_validator/Element_Tree.cpp | 2 | ||||
-rw-r--r-- | ACEXML/parser/parser/Parser.cpp | 283 |
14 files changed, 195 insertions, 219 deletions
diff --git a/ACEXML/apps/svcconf/Svcconf_Handler.cpp b/ACEXML/apps/svcconf/Svcconf_Handler.cpp index bc691ae2c19..808d458f3bb 100644 --- a/ACEXML/apps/svcconf/Svcconf_Handler.cpp +++ b/ACEXML/apps/svcconf/Svcconf_Handler.cpp @@ -127,7 +127,7 @@ ACEXML_Svcconf_Handler::endElement (const ACEXML_Char *, if (ACE_OS::strcmp (mp->name (), active_info->name ()) != 0) { ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("warning: assigning Module_Type name %s to Module %s since names differ\n"), + ACE_TEXT ("warning: assigning Module_Type name %s to Module %s since names differ\n"), active_info->name (), mp->name ())); mp->name (active_info->name ()); @@ -253,10 +253,10 @@ ACEXML_Svcconf_Handler::processingInstruction (const ACEXML_Char *, } void -ACEXML_Svcconf_Handler::setDocumentLocator (ACEXML_Locator *, +ACEXML_Svcconf_Handler::setDocumentLocator (ACEXML_Locator* locator, ACEXML_Env &) { - // no-op + this->locator_ = locator; } void @@ -485,7 +485,7 @@ ACEXML_Svcconf_Handler::error (ACEXML_SAXParseException& ex, ACEXML_Env &) // ACE_THROW_SPEC ((ACEXML_SAXException)) { - ACE_DEBUG ((LM_DEBUG, "%s: line :%d col: %d ", this->getSystemId(), + ACE_DEBUG ((LM_DEBUG, "%s: line :%d col: %d ", this->locator_->getSystemId(), this->locator_->getLineNumber(), this->locator_->getColumnNumber())); ex.print(); @@ -496,7 +496,7 @@ ACEXML_Svcconf_Handler::fatalError (ACEXML_SAXParseException& ex, ACEXML_Env &) // ACE_THROW_SPEC ((ACEXML_SAXException)) { - ACE_DEBUG ((LM_DEBUG, "%s: line :%d col: %d ", this->getSystemId(), + ACE_DEBUG ((LM_DEBUG, "%s: line :%d col: %d ", this->locator_->getSystemId(), this->locator_->getLineNumber(), this->locator_->getColumnNumber())); ex.print(); @@ -507,7 +507,7 @@ ACEXML_Svcconf_Handler::warning (ACEXML_SAXParseException& ex, ACEXML_Env &) // ACE_THROW_SPEC ((ACEXML_SAXException)) { - ACE_DEBUG ((LM_DEBUG, "%s: line :%d col: %d ", this->getSystemId(), + ACE_DEBUG ((LM_DEBUG, "%s: line :%d col: %d ", this->locator_->getSystemId(), this->locator_->getLineNumber(), this->locator_->getColumnNumber())); ex.print(); diff --git a/ACEXML/apps/svcconf/Svcconf_Handler.h b/ACEXML/apps/svcconf/Svcconf_Handler.h index 8bdd1f0201c..3ee6567be98 100644 --- a/ACEXML/apps/svcconf/Svcconf_Handler.h +++ b/ACEXML/apps/svcconf/Svcconf_Handler.h @@ -299,6 +299,8 @@ private: ACE_Parsed_Info parsed_info_; ACE_Parsed_Info stream_info_; + + ACEXML_Locator* locator_; }; #if defined (__ACEXML_INLINE__) diff --git a/ACEXML/common/FileCharStream.cpp b/ACEXML/common/FileCharStream.cpp index 885ba18f0ad..1f66991c884 100644 --- a/ACEXML/common/FileCharStream.cpp +++ b/ACEXML/common/FileCharStream.cpp @@ -22,7 +22,7 @@ ACEXML_FileCharStream::open (const ACEXML_Char *name) delete[] this->filename_; this->filename_ = 0; - this->infile_ = ACE_OS::fopen (name, ACE_LIB_TEXT ("r")); + this->infile_ = ACE_OS::fopen (name, ACE_TEXT ("r")); if (this->infile_ == NULL) return -1; @@ -58,10 +58,8 @@ ACEXML_FileCharStream::close (void) int ACEXML_FileCharStream::get (ACEXML_Char& ch) { - // @@ Error checking? - ch = (unsigned char) fgetc (this->infile_); - - return (((char) ch) == EOF ? -1 :0); + ch = (ACEXML_Char) ACE_OS::fgetc (this->infile_); + return (ACE_OS::feof(this->infile_) ? -1 : 0); } int @@ -74,7 +72,7 @@ ACEXML_FileCharStream::read (ACEXML_Char *str, int ACEXML_FileCharStream::peek (void) { - ACEXML_Char ch = ::fgetc (this->infile_); - ::ungetc (ch, this->infile_); + ACEXML_Char ch = ACE_OS::fgetc (this->infile_); + ACE_OS::ungetc (ch, this->infile_); return ch; } diff --git a/ACEXML/common/HttpCharStream.cpp b/ACEXML/common/HttpCharStream.cpp index 9377fc5c4e0..beeb6806390 100644 --- a/ACEXML/common/HttpCharStream.cpp +++ b/ACEXML/common/HttpCharStream.cpp @@ -267,8 +267,8 @@ ACEXML_HttpCharStream::close (void) int ACEXML_HttpCharStream::get (ACEXML_Char& ch) { - ch = (unsigned char) this->stream_->get_char(); - return (((char) ch) == EOF ? -1 :0); + ch = (ACEXML_Char) this->stream_->get_char(); + return (ch == (ACEXML_Char)EOF ? -1 :0); } int diff --git a/ACEXML/common/XMLFilterImpl.cpp b/ACEXML/common/XMLFilterImpl.cpp index c1b70a2cad1..464ac531f08 100644 --- a/ACEXML/common/XMLFilterImpl.cpp +++ b/ACEXML/common/XMLFilterImpl.cpp @@ -38,7 +38,7 @@ ACEXML_XMLFilterImpl::parse (ACEXML_InputSource *input, { if (this->setupParser () < 0) { - xmlenv.exception (new ACEXML_SAXException (ACE_LIB_TEXT ("No Parent available"))); + xmlenv.exception (new ACEXML_SAXException (ACE_TEXT ("No Parent available"))); return; } this->parent_->parse (input, xmlenv); @@ -52,7 +52,7 @@ ACEXML_XMLFilterImpl::parse (const ACEXML_Char *systemId, { if (this->setupParser () < 0) { - xmlenv.exception (new ACEXML_SAXException (ACE_LIB_TEXT ("No Parent available"))); + xmlenv.exception (new ACEXML_SAXException (ACE_TEXT ("No Parent available"))); return; } diff --git a/ACEXML/examples/SAXPrint/Print_Handler.cpp b/ACEXML/examples/SAXPrint/Print_Handler.cpp index b1db82d32cc..be539a36a11 100644 --- a/ACEXML/examples/SAXPrint/Print_Handler.cpp +++ b/ACEXML/examples/SAXPrint/Print_Handler.cpp @@ -29,7 +29,7 @@ ACEXML_Print_Handler::characters (const ACEXML_Char *cdata, ACE_UNUSED_ARG (xmlenv); ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("* Event characters () ** start: %d end: %d ***************\n%s\n- End event characters () ---------------\n"), + ACE_TEXT ("* Event characters () ** start: %d end: %d ***************\n%s\n- End event characters () ---------------\n"), start, end, cdata)); } @@ -40,7 +40,7 @@ ACEXML_Print_Handler::endDocument (ACEXML_Env &xmlenv) ACE_UNUSED_ARG (xmlenv); ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("* Event endDocument () ***************\n"))); + ACE_TEXT ("* Event endDocument () ***************\n"))); } void @@ -53,7 +53,7 @@ ACEXML_Print_Handler::endElement (const ACEXML_Char *uri, ACE_UNUSED_ARG (xmlenv); ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("* Event endElement (%s, %s, %s) ***************\n"), + ACE_TEXT ("* Event endElement (%s, %s, %s) ***************\n"), uri, name, qName)); } @@ -65,7 +65,7 @@ ACEXML_Print_Handler::endPrefixMapping (const ACEXML_Char *prefix, ACE_UNUSED_ARG (xmlenv); ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("* Event endPrefixMapping (%s) ***************\n"), + ACE_TEXT ("* Event endPrefixMapping (%s) ***************\n"), prefix)); } @@ -79,7 +79,7 @@ ACEXML_Print_Handler::ignorableWhitespace (const ACEXML_Char *, ACE_UNUSED_ARG (xmlenv); ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("* Event ignorableWhitespace () ***************\n"))); + ACE_TEXT ("* Event ignorableWhitespace () ***************\n"))); } void @@ -91,7 +91,7 @@ ACEXML_Print_Handler::processingInstruction (const ACEXML_Char *target, ACE_UNUSED_ARG (xmlenv); ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("* Event processingInstruction (%s, %s) ***************\n"), + ACE_TEXT ("* Event processingInstruction (%s, %s) ***************\n"), target, data)); } @@ -102,7 +102,7 @@ ACEXML_Print_Handler::setDocumentLocator (ACEXML_Locator * locator, ACE_UNUSED_ARG (xmlenv); this->locator_ = locator; ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("* Event setDocumentLocator () ***************\n"))); + ACE_TEXT ("* Event setDocumentLocator () ***************\n"))); } void @@ -113,7 +113,7 @@ ACEXML_Print_Handler::skippedEntity (const ACEXML_Char *name, ACE_UNUSED_ARG (xmlenv); ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("* Event skippedEntity (%s) ***************\n"), + ACE_TEXT ("* Event skippedEntity (%s) ***************\n"), name)); } @@ -124,7 +124,7 @@ ACEXML_Print_Handler::startDocument (ACEXML_Env &xmlenv) ACE_UNUSED_ARG (xmlenv); ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("* Event startDocument () ***************\n"))); + ACE_TEXT ("* Event startDocument () ***************\n"))); } void @@ -138,14 +138,14 @@ ACEXML_Print_Handler::startElement (const ACEXML_Char *uri, ACE_UNUSED_ARG (xmlenv); ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("* Event startElement (%s, %s, %s) ***************\n"), + ACE_TEXT ("* Event startElement (%s, %s, %s) ***************\n"), uri, name, qName)); if (alist != 0) for (size_t i = 0; i < alist->getLength (); ++i) { ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT (" %s = \"%s\"\n"), + ACE_TEXT (" %s = \"%s\"\n"), alist->getQName (i), alist->getValue (i))); } } @@ -157,9 +157,9 @@ ACEXML_Print_Handler::startPrefixMapping (const ACEXML_Char * prefix, // ACE_THROW_SPEC ((ACEXML_SAXException)) { ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("* Event startPrefixMapping () ***************\n"))); + ACE_TEXT ("* Event startPrefixMapping () ***************\n"))); ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("Prefix = %s, URI = %s\n"), prefix, uri)); + ACE_TEXT ("Prefix = %s, URI = %s\n"), prefix, uri)); } // *** Methods inherit from ACEXML_DTDHandler. @@ -172,20 +172,20 @@ ACEXML_Print_Handler::notationDecl (const ACEXML_Char *name, // ACE_THROW_SPEC ((ACEXML_SAXException)) { ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("* Event notationDecl: (%s) "), + ACE_TEXT ("* Event notationDecl: (%s) "), name)); if (publicID == 0) ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("SYSTEM %s\n"), + ACE_TEXT ("SYSTEM %s\n"), systemID)); else if (systemID == 0) ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("PUBLIC %s\n"), + ACE_TEXT ("PUBLIC %s\n"), publicID)); else ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("PUBLIC %s %s\n"), + ACE_TEXT ("PUBLIC %s %s\n"), publicID, systemID)); } @@ -198,20 +198,20 @@ ACEXML_Print_Handler::unparsedEntityDecl (const ACEXML_Char *name, // ACE_THROW_SPEC ((ACEXML_SAXException)) { ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("* Unparsed Entity: %s"), + ACE_TEXT ("* Unparsed Entity: %s"), name)); if (publicID == 0) ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT (" SYSTEM %s"), + ACE_TEXT (" SYSTEM %s"), systemID)); else ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT (" PUBLIC %s %s"), + ACE_TEXT (" PUBLIC %s %s"), publicID, systemID)); ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT (" NDATA %s\n"), + ACE_TEXT (" NDATA %s\n"), notationName)); } diff --git a/ACEXML/examples/SAXPrint/SAXPrint_Handler.cpp b/ACEXML/examples/SAXPrint/SAXPrint_Handler.cpp index 3f15cef4e80..56cc3b4c0c1 100644 --- a/ACEXML/examples/SAXPrint/SAXPrint_Handler.cpp +++ b/ACEXML/examples/SAXPrint/SAXPrint_Handler.cpp @@ -31,7 +31,7 @@ ACEXML_SAXPrint_Handler::characters (const ACEXML_Char *cdata, ACE_UNUSED_ARG (end); ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("%s"), + ACE_TEXT ("%s"), cdata)); } @@ -41,7 +41,7 @@ ACEXML_SAXPrint_Handler::endDocument (ACEXML_Env &xmlenv) { ACE_UNUSED_ARG (xmlenv); - ACE_DEBUG ((LM_DEBUG, ACE_LIB_TEXT ("\n"))); + ACE_DEBUG ((LM_DEBUG, ACE_TEXT ("\n"))); } void @@ -56,7 +56,7 @@ ACEXML_SAXPrint_Handler::endElement (const ACEXML_Char *, this->dec_indent (); this->print_indent (); ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("</%s>"), + ACE_TEXT ("</%s>"), qName)); } @@ -68,7 +68,7 @@ ACEXML_SAXPrint_Handler::endPrefixMapping (const ACEXML_Char *prefix, ACE_UNUSED_ARG (xmlenv); ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("* Event endPrefixMapping (%s) ***************\n"), + ACE_TEXT ("* Event endPrefixMapping (%s) ***************\n"), prefix)); } @@ -82,7 +82,7 @@ ACEXML_SAXPrint_Handler::ignorableWhitespace (const ACEXML_Char *, ACE_UNUSED_ARG (xmlenv); ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("* Event ignorableWhitespace () ***************\n"))); + ACE_TEXT ("* Event ignorableWhitespace () ***************\n"))); } void @@ -95,7 +95,7 @@ ACEXML_SAXPrint_Handler::processingInstruction (const ACEXML_Char *target, this->print_indent (); ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("<?%s %s>\n"), + ACE_TEXT ("<?%s %s>\n"), target, data)); } @@ -106,7 +106,7 @@ ACEXML_SAXPrint_Handler::setDocumentLocator (ACEXML_Locator *, ACE_UNUSED_ARG (xmlenv); ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("* Event setDocumentLocator () ***************\n"))); + ACE_TEXT ("* Event setDocumentLocator () ***************\n"))); } void @@ -117,7 +117,7 @@ ACEXML_SAXPrint_Handler::skippedEntity (const ACEXML_Char *name, ACE_UNUSED_ARG (xmlenv); ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("* Event skippedEntity (%s) ***************\n"), + ACE_TEXT ("* Event skippedEntity (%s) ***************\n"), name)); } @@ -128,7 +128,7 @@ ACEXML_SAXPrint_Handler::startDocument (ACEXML_Env &xmlenv) ACE_UNUSED_ARG (xmlenv); ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("* Event startDocument () ***************\n"))); + ACE_TEXT ("* Event startDocument () ***************\n"))); } void @@ -143,16 +143,16 @@ ACEXML_SAXPrint_Handler::startElement (const ACEXML_Char *, this->print_indent (); - ACE_DEBUG ((LM_DEBUG, ACE_LIB_TEXT ("<%s"), + ACE_DEBUG ((LM_DEBUG, ACE_TEXT ("<%s"), qName)); if (alist != 0) for (size_t i = 0; i < alist->getLength (); ++i) { ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT (" %s = \"%s\""), + ACE_TEXT (" %s = \"%s\""), alist->getQName (i), alist->getValue (i))); } - ACE_DEBUG ((LM_DEBUG, ACE_LIB_TEXT (">"))); + ACE_DEBUG ((LM_DEBUG, ACE_TEXT (">"))); this->inc_indent (); } @@ -163,9 +163,9 @@ ACEXML_SAXPrint_Handler::startPrefixMapping (const ACEXML_Char * prefix, // ACE_THROW_SPEC ((ACEXML_SAXException)) { ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("* Event startPrefixMapping () ***************\n"))); + ACE_TEXT ("* Event startPrefixMapping () ***************\n"))); ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("Prefix = %s, URI = %s\n"), prefix, uri)); + ACE_TEXT ("Prefix = %s, URI = %s\n"), prefix, uri)); } @@ -236,7 +236,7 @@ ACEXML_SAXPrint_Handler::warning (ACEXML_SAXParseException &, void ACEXML_SAXPrint_Handler::print_indent (void) { - ACE_DEBUG ((LM_DEBUG, ACE_LIB_TEXT ("\n"))); + ACE_DEBUG ((LM_DEBUG, ACE_TEXT ("\n"))); for (size_t i = 0; i < this->indent_; ++i) - ACE_DEBUG ((LM_DEBUG, ACE_LIB_TEXT (" "))); + ACE_DEBUG ((LM_DEBUG, ACE_TEXT (" "))); } diff --git a/ACEXML/examples/SAXPrint/main.cpp b/ACEXML/examples/SAXPrint/main.cpp index a6fd619c09e..2222e8950c4 100644 --- a/ACEXML/examples/SAXPrint/main.cpp +++ b/ACEXML/examples/SAXPrint/main.cpp @@ -4,7 +4,6 @@ #include "ACEXML/common/HttpCharStream.h" #include "ACEXML/common/StrCharStream.h" #include "ACEXML/parser/parser/Parser.h" -#include "ACEXML/parser/parser/Parser.h" #include "Print_Handler.h" #include "SAXPrint_Handler.h" #include "ace/Get_Opt.h" @@ -27,15 +26,15 @@ usage (const ACE_TCHAR* program) int ACE_TMAIN (int argc, ACE_TCHAR *argv[]) { - ACE_TCHAR *filename = 0; + ACEXML_Char* filename = 0; int sax = 0; // Use SAXPrint handler or not. int str = 0; ACEXML_Char* url = 0; ACE_Get_Opt get_opt (argc, argv, ACE_TEXT ("sf:lu:")); - char c; + ACEXML_Char c; - while ((c = get_opt ()) != EOF) + while ((c = (ACEXML_Char)get_opt ()) != (ACEXML_Char)-1) { switch (c) { diff --git a/ACEXML/examples/svcconf/Svcconf_Handler.cpp b/ACEXML/examples/svcconf/Svcconf_Handler.cpp index 588caeb34ac..6b13230edd3 100644 --- a/ACEXML/examples/svcconf/Svcconf_Handler.cpp +++ b/ACEXML/examples/svcconf/Svcconf_Handler.cpp @@ -258,10 +258,10 @@ ACEXML_Svcconf_Handler::startElement (const ACEXML_Char *, for (size_t i = 0; i < alist->getLength (); ++i) { ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT (" %s = \"%s\""), + ACE_TEXT (" %s = \"%s\""), alist->getQName (i), alist->getValue (i))); } - ACE_DEBUG ((LM_DEBUG, ACE_LIB_TEXT (">"))); + ACE_DEBUG ((LM_DEBUG, ACE_TEXT (">"))); } void diff --git a/ACEXML/parser/debug_validator/Debug_Attributes_Builder.cpp b/ACEXML/parser/debug_validator/Debug_Attributes_Builder.cpp index 633f861e53f..7b486cc2deb 100644 --- a/ACEXML/parser/debug_validator/Debug_Attributes_Builder.cpp +++ b/ACEXML/parser/debug_validator/Debug_Attributes_Builder.cpp @@ -45,7 +45,7 @@ ACEXML_Debug_Attribute_Builder::setAttType (const ATT_TYPE type, this->type_ = type; return 0; } - xmlenv.exception (new ACEXML_SAXParseException (ACE_LIB_TEXT("Attribute type redefinition in Debug Validator"))); + xmlenv.exception (new ACEXML_SAXParseException (ACE_TEXT("Attribute type redefinition in Debug Validator"))); return -1; } @@ -195,7 +195,7 @@ ACEXML_Debug_Attributes_Builder::insertAttribute (ACEXML_Attribute_Def_Builder * this->attributes_.bind (attname, *ptr); return 0; } - xmlenv.exception (new ACEXML_SAXParseException (ACE_LIB_TEXT("ACEXML_Debug_Attributes_Builder internal error"))); + xmlenv.exception (new ACEXML_SAXParseException (ACE_TEXT("ACEXML_Debug_Attributes_Builder internal error"))); return -1; } diff --git a/ACEXML/parser/debug_validator/Debug_DTD_Manager.cpp b/ACEXML/parser/debug_validator/Debug_DTD_Manager.cpp index 05af2aa7d66..7d48a74bc35 100644 --- a/ACEXML/parser/debug_validator/Debug_DTD_Manager.cpp +++ b/ACEXML/parser/debug_validator/Debug_DTD_Manager.cpp @@ -33,7 +33,7 @@ ACEXML_Debug_DTD_Manager::insertElement_Definition (ACEXML_Element_Def_Builder * return 0; } - xmlenv.exception (new ACEXML_SAXParseException (ACE_LIB_TEXT("ACEXML_Debug_Attributes_Builder internal error"))); + xmlenv.exception (new ACEXML_SAXParseException (ACE_TEXT("ACEXML_Debug_Attributes_Builder internal error"))); return -1; } @@ -58,7 +58,7 @@ ACEXML_Debug_DTD_Manager::insertAttributes_Definition (ACEXML_Attributes_Def_Bui return 0; } - xmlenv.exception (new ACEXML_SAXParseException (ACE_LIB_TEXT("ACEXML_Debug_Attributes_Builder internal error"))); + xmlenv.exception (new ACEXML_SAXParseException (ACE_TEXT("ACEXML_Debug_Attributes_Builder internal error"))); return -1; } diff --git a/ACEXML/parser/debug_validator/Debug_Element_Builder.cpp b/ACEXML/parser/debug_validator/Debug_Element_Builder.cpp index f3cdfbe52ab..92a543c5002 100644 --- a/ACEXML/parser/debug_validator/Debug_Element_Builder.cpp +++ b/ACEXML/parser/debug_validator/Debug_Element_Builder.cpp @@ -36,7 +36,7 @@ ACEXML_Debug_Element_Builder::setContentType (CONTENT_TYPE type, return 0; } - xmlenv.exception (new ACEXML_SAXParseException (ACE_LIB_TEXT("Element type redefinition in Debug_Validator."))); + xmlenv.exception (new ACEXML_SAXParseException (ACE_TEXT("Element type redefinition in Debug_Validator."))); return -1; } diff --git a/ACEXML/parser/debug_validator/Element_Tree.cpp b/ACEXML/parser/debug_validator/Element_Tree.cpp index 0afb5135b41..e9275061b52 100644 --- a/ACEXML/parser/debug_validator/Element_Tree.cpp +++ b/ACEXML/parser/debug_validator/Element_Tree.cpp @@ -45,7 +45,7 @@ void ACEXML_Element_Tree_List_Node::dump (void) { ACEXML_Element_Tree_Node *ptr = this->head_; - const ACEXML_Char *separator = (this->type_ == SEQUENCE) ? ACE_LIB_TEXT(" , ") : ACE_LIB_TEXT(" | "); + const ACEXML_Char *separator = (this->type_ == SEQUENCE) ? ACE_TEXT(" , ") : ACE_TEXT(" | "); cout << "("; diff --git a/ACEXML/parser/parser/Parser.cpp b/ACEXML/parser/parser/Parser.cpp index 0265841c155..b9e42f9f560 100644 --- a/ACEXML/parser/parser/Parser.cpp +++ b/ACEXML/parser/parser/Parser.cpp @@ -173,7 +173,7 @@ ACEXML_Parser::parse (ACEXML_InputSource *input, { if (input == 0 || (this->instream_ = input->getCharStream ()) == 0) { - this->report_fatal_error(ACE_LIB_TEXT ("Invalid input source"), xmlenv); + this->report_fatal_error(ACE_TEXT ("Invalid input source"), xmlenv); return; } @@ -199,7 +199,7 @@ ACEXML_Parser::parse (ACEXML_InputSource *input, { if (this->skip_whitespace (0) != '<') { - this->report_fatal_error (ACE_LIB_TEXT ("Expecting '<'"), xmlenv); + this->report_fatal_error (ACE_TEXT ("Expecting '<'"), xmlenv); return; } ACEXML_Char fwd = this->peek (); @@ -220,14 +220,14 @@ ACEXML_Parser::parse (ACEXML_InputSource *input, { if (this->grok_comment () < 0) { - this->report_fatal_error(ACE_LIB_TEXT ("Invalid comment"), + this->report_fatal_error(ACE_TEXT ("Invalid comment"), xmlenv); return; } } else { - this->report_fatal_error (ACE_LIB_TEXT ("Duplicate DOCTYPE definitions"), xmlenv); + this->report_fatal_error (ACE_TEXT ("Duplicate DOCTYPE definitions"), xmlenv); return; } break; @@ -236,7 +236,7 @@ ACEXML_Parser::parse (ACEXML_InputSource *input, ACEXML_CHECK; break; case 0: - this->report_fatal_error (ACE_LIB_TEXT ("Unexpected EOF"), xmlenv); + this->report_fatal_error (ACE_TEXT ("Unexpected EOF"), xmlenv); return; default: // Root element begins prolog_done = 1; @@ -272,9 +272,9 @@ void ACEXML_Parser::parse_xml_prolog (ACEXML_Env &xmlenv) // ACE_THROW_SPEC ((ACEXML_SAXException)) { - if (this->parse_token (ACE_LIB_TEXT("<?xml")) < 0) + if (this->parse_token (ACE_TEXT("<?xml")) < 0) { - this->report_fatal_error(ACE_LIB_TEXT ("Invalid XMLDecl ('<?xml' ?)"), + this->report_fatal_error(ACE_TEXT ("Invalid XMLDecl ('<?xml' ?)"), xmlenv); return; } @@ -282,11 +282,11 @@ ACEXML_Parser::parse_xml_prolog (ACEXML_Env &xmlenv) ACEXML_Char *astring; if (this->skip_whitespace (0) != 'v' // Discard whitespace - || (this->parse_token (ACE_LIB_TEXT("ersion")) < 0) + || (this->parse_token (ACE_TEXT("ersion")) < 0) || this->skip_equal () != 0 || this->get_quoted_string (astring) != 0) { - this->report_fatal_error (ACE_LIB_TEXT ("Unrecognized XMLDecl ('version'?)"), + this->report_fatal_error (ACE_TEXT ("Unrecognized XMLDecl ('version'?)"), xmlenv); return; } @@ -306,13 +306,13 @@ ACEXML_Parser::parse_xml_prolog (ACEXML_Env &xmlenv) } else if (xmldecl_state == 0 && fwd == 'e') { - if ((this->parse_token (ACE_LIB_TEXT("ncoding")) == 0) && + if ((this->parse_token (ACE_TEXT("ncoding")) == 0) && this->skip_equal () == 0 && this->get_quoted_string (astring) == 0) { if (seen_encoding) { - this->report_fatal_error (ACE_LIB_TEXT ("Duplicate encoding defined"), + this->report_fatal_error (ACE_TEXT ("Duplicate encoding defined"), xmlenv); return; } @@ -327,17 +327,17 @@ ACEXML_Parser::parse_xml_prolog (ACEXML_Env &xmlenv) } else if (xmldecl_state < 2 && fwd == 's') { - if ((this->parse_token (ACE_LIB_TEXT("tandalone")) == 0) && + if ((this->parse_token (ACE_TEXT("tandalone")) == 0) && this->skip_equal () == 0 && this->get_quoted_string (astring) == 0) { xmldecl_state = 2; - if (ACE_OS::strcmp (astring, ACE_LIB_TEXT ("yes")) == 0) + if (ACE_OS::strcmp (astring, ACE_TEXT ("yes")) == 0) { // @@ This is a standalone XML file. continue; } - else if (ACE_OS::strcmp (astring, ACE_LIB_TEXT ("no")) == 0) + else if (ACE_OS::strcmp (astring, ACE_TEXT ("no")) == 0) { // @@ This is not a stand alone XML file. continue; @@ -348,11 +348,11 @@ ACEXML_Parser::parse_xml_prolog (ACEXML_Env &xmlenv) else break; } - if (this->parse_token (ACE_LIB_TEXT ("?>")) < 0) + if (this->parse_token (ACE_TEXT ("?>")) < 0) break; return; } // End parsing XML Decl. - this->report_fatal_error (ACE_LIB_TEXT ("Unrecognized XML Decl ('standalone'?)"), + this->report_fatal_error (ACE_TEXT ("Unrecognized XML Decl ('standalone'?)"), xmlenv); return; } @@ -388,16 +388,16 @@ ACEXML_Parser::parse_processing_instruction (ACEXML_Env &xmlenv) { if (this->get () != '?') { // How did we get here? - this->report_fatal_error(ACE_LIB_TEXT ("Internal error"), xmlenv); + this->report_fatal_error(ACE_TEXT ("Internal error"), xmlenv); return -1; } const ACEXML_Char *pitarget = this->read_name (); ACEXML_Char *instruction = 0; - if (ACE_OS::strcasecmp (ACE_LIB_TEXT ("xml"), pitarget) != 0) + if (ACE_OS::strcasecmp (ACE_TEXT ("xml"), pitarget) != 0) { // Invalid PITarget name. - this->report_fatal_error(ACE_LIB_TEXT ("PITarget name cannot start with 'xml'"), xmlenv); + this->report_fatal_error(ACE_TEXT ("PITarget name cannot start with 'xml'"), xmlenv); return -1; } @@ -443,9 +443,9 @@ int ACEXML_Parser::parse_doctypedecl (ACEXML_Env &xmlenv) // ACE_THROW_SPEC ((ACEXML_SAXException)) { - if (this->parse_token (ACE_LIB_TEXT ("DOCTYPE")) < 0) + if (this->parse_token (ACE_TEXT ("DOCTYPE")) < 0) { - this->report_fatal_error(ACE_LIB_TEXT ("Expecting keyword 'DOCTYPE'"), + this->report_fatal_error(ACE_TEXT ("Expecting keyword 'DOCTYPE'"), xmlenv); return -1; } @@ -453,7 +453,7 @@ ACEXML_Parser::parse_doctypedecl (ACEXML_Env &xmlenv) ACEXML_Char nextch = this->skip_whitespace (0); if (nextch == 0) { - this->report_fatal_error(ACE_LIB_TEXT ("Expecting a DOCTYPE name"), + this->report_fatal_error(ACE_TEXT ("Expecting a DOCTYPE name"), xmlenv); return -1; } @@ -471,11 +471,11 @@ ACEXML_Parser::parse_doctypedecl (ACEXML_Env &xmlenv) return -1; else if (this->dtd_public_ == 0) ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("ACEXML Parser got external DTD id: SYSTEM %s\n"), + ACE_TEXT ("ACEXML Parser got external DTD id: SYSTEM %s\n"), this->dtd_system_)); else ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("ACEXML Parser got DTD external id: PUBLIC %s %s\n"), + ACE_TEXT ("ACEXML Parser got DTD external id: PUBLIC %s %s\n"), this->dtd_public_, this->dtd_system_)); } @@ -490,7 +490,7 @@ ACEXML_Parser::parse_doctypedecl (ACEXML_Env &xmlenv) // this is an XML document without a dectypedecl. return 0; case '0': - this->report_fatal_error (ACE_LIB_TEXT ("Unexpected EOF"), xmlenv); + this->report_fatal_error (ACE_TEXT ("Unexpected EOF"), xmlenv); return -1; default: break; @@ -498,7 +498,7 @@ ACEXML_Parser::parse_doctypedecl (ACEXML_Env &xmlenv) if (this->skip_whitespace (0) != '>') { - this->report_fatal_error(ACE_LIB_TEXT ("Internal error"), xmlenv); + this->report_fatal_error(ACE_TEXT ("Internal error"), xmlenv); return -1; } return 0; @@ -512,13 +512,13 @@ ACEXML_Parser::parse_element (int is_root, ACEXML_Env &xmlenv) const ACEXML_Char *startname = this->read_name (); if (startname == 0) { - this->report_fatal_error (ACE_LIB_TEXT ("Unexpected EOF"), xmlenv); + this->report_fatal_error (ACE_TEXT ("Unexpected EOF"), xmlenv); return; } if (is_root && this->doctype_ != 0 && ACE_OS::strcmp (startname, this->doctype_) != 0) { - this->report_fatal_error (ACE_LIB_TEXT ("Root element missing"), xmlenv); + this->report_fatal_error (ACE_TEXT ("Root element missing"), xmlenv); return; } ACEXML_AttributesImpl attributes; @@ -535,12 +535,12 @@ ACEXML_Parser::parse_element (int is_root, ACEXML_Env &xmlenv) switch (ch) { case 0: - this->report_fatal_error(ACE_LIB_TEXT ("Internal error"), xmlenv); + this->report_fatal_error(ACE_TEXT ("Internal error"), xmlenv); return; case '/': if (this->get () != '>') { - this->report_fatal_error(ACE_LIB_TEXT ("Expecting '>'"), xmlenv); + this->report_fatal_error(ACE_TEXT ("Expecting '>'"), xmlenv); return; } else @@ -585,13 +585,13 @@ ACEXML_Parser::parse_element (int is_root, ACEXML_Env &xmlenv) this->skip_equal () != 0 || this->get_quoted_string (attvalue) != 0) { - this->report_fatal_error(ACE_LIB_TEXT ("Error reading attribute"),xmlenv); + this->report_fatal_error(ACE_TEXT ("Error reading attribute"),xmlenv); return; } // Handling new namespace if any. Notice that the order of // namespace declaration does matter. - if (ACE_OS::strncmp (attname, ACE_LIB_TEXT("xmlns"), 5) == 0) + if (ACE_OS::strncmp (attname, ACE_TEXT("xmlns"), 5) == 0) { if (this->namespaces_) { @@ -605,7 +605,7 @@ ACEXML_Parser::parse_element (int is_root, ACEXML_Env &xmlenv) if (this->xml_namespace_.declarePrefix (ns_name, attvalue) == -1) { - this->report_fatal_error(ACE_LIB_TEXT ("Duplicate namespace prefix"),xmlenv); + this->report_fatal_error(ACE_TEXT ("Duplicate namespace prefix"),xmlenv); return; } } @@ -617,13 +617,13 @@ ACEXML_Parser::parse_element (int is_root, ACEXML_Env &xmlenv) default_attribute_type, attvalue) == -1) { - this->report_fatal_error(ACE_LIB_TEXT ("Duplicate attribute found"),xmlenv); + this->report_fatal_error(ACE_TEXT ("Duplicate attribute found"),xmlenv); return; } } if (!this->namespaces_ && !this->namespace_prefixes_) { - this->report_fatal_error(ACE_LIB_TEXT ("Both namespaces feature and namespace_prefixes feature are false. Illegal Mode"), xmlenv); + this->report_fatal_error(ACE_TEXT ("Both namespaces feature and namespace_prefixes feature are false. Illegal Mode"), xmlenv); return; } } @@ -635,7 +635,7 @@ ACEXML_Parser::parse_element (int is_root, ACEXML_Env &xmlenv) default_attribute_type, attvalue) == -1) { - this->report_fatal_error(ACE_LIB_TEXT ("Duplicate attribute found"),xmlenv); + this->report_fatal_error(ACE_TEXT ("Duplicate attribute found"),xmlenv); return; } } @@ -653,7 +653,7 @@ ACEXML_Parser::parse_element (int is_root, ACEXML_Env &xmlenv) switch (ch) { case 0: - this->report_fatal_error(ACE_LIB_TEXT ("Internal error"), xmlenv); + this->report_fatal_error(ACE_TEXT ("Internal error"), xmlenv); return; case '<': // Push out old 'characters' event. @@ -675,7 +675,7 @@ ACEXML_Parser::parse_element (int is_root, ACEXML_Env &xmlenv) { if (this->grok_comment () < 0) { - this->report_fatal_error(ACE_LIB_TEXT ("Error parsing comment"), xmlenv); + this->report_fatal_error(ACE_TEXT ("Error parsing comment"), xmlenv); return; } } @@ -686,7 +686,7 @@ ACEXML_Parser::parse_element (int is_root, ACEXML_Env &xmlenv) } else { - this->report_fatal_error(ACE_LIB_TEXT ("Unexpected character"), xmlenv); + this->report_fatal_error(ACE_TEXT ("Unexpected character"), xmlenv); return; } break; @@ -701,12 +701,12 @@ ACEXML_Parser::parse_element (int is_root, ACEXML_Env &xmlenv) if (endname == 0 || ACE_OS::strcmp (startname, endname) != 0) { - this->report_fatal_error(ACE_LIB_TEXT ("Mismatched End-tag encountered"), xmlenv); + this->report_fatal_error(ACE_TEXT ("Mismatched End-tag encountered"), xmlenv); return ; } if (this->skip_whitespace (0) != '>') { - this->report_fatal_error(ACE_LIB_TEXT ("Expecting '>' in an end-tag"), xmlenv); + this->report_fatal_error(ACE_TEXT ("Expecting '>' in an end-tag"), xmlenv); return; } this->content_handler_->endElement (ns_uri, ns_lname, endname, @@ -748,7 +748,7 @@ ACEXML_Parser::parse_element (int is_root, ACEXML_Env &xmlenv) if (replace == 0) { - this->report_fatal_error(ACE_LIB_TEXT ("Internal error"), + this->report_fatal_error(ACE_TEXT ("Internal error"), xmlenv); return; } @@ -913,9 +913,9 @@ ACEXML_Parser::parse_reference (void) int ACEXML_Parser::parse_cdata (ACEXML_Env &xmlenv) { - if (this->parse_token (ACE_LIB_TEXT ("[CDATA[")) < 0) + if (this->parse_token (ACE_TEXT ("[CDATA[")) < 0) { - this->report_fatal_error(ACE_LIB_TEXT ("'[CDATA[' expected"), xmlenv); + this->report_fatal_error(ACE_TEXT ("'[CDATA[' expected"), xmlenv); return -1; } @@ -989,7 +989,7 @@ ACEXML_Parser::try_grow_cdata (size_t size, size_t &len, ACEXML_Env &xmlenv) ACEXML_Char *cdata = this->obstack_.freeze (); if (cdata == 0) { - this->report_fatal_error(ACE_LIB_TEXT ("Internal Error growing CDATA buffer"), xmlenv); + this->report_fatal_error(ACE_TEXT ("Internal Error growing CDATA buffer"), xmlenv); return -1; } this->content_handler_->characters (cdata, @@ -1001,7 +1001,7 @@ ACEXML_Parser::try_grow_cdata (size_t size, size_t &len, ACEXML_Env &xmlenv) if (this->obstack_.request (size) == 0) return 0; } - this->report_fatal_error(ACE_LIB_TEXT ("Internal Error, buffer overflowed"), xmlenv); + this->report_fatal_error(ACE_TEXT ("Internal Error, buffer overflowed"), xmlenv); return -1; } return 0; @@ -1041,7 +1041,7 @@ ACEXML_Parser::parse_internal_dtd (ACEXML_Env &xmlenv) break; default: - this->report_fatal_error(ACE_LIB_TEXT ("Invalid keyword in decl spec"), xmlenv); + this->report_fatal_error(ACE_TEXT ("Invalid keyword in decl spec"), xmlenv); return -1; } break; @@ -1059,16 +1059,16 @@ ACEXML_Parser::parse_internal_dtd (ACEXML_Env &xmlenv) case '-': // a comment. if (this->grok_comment () < 0) { - this->report_fatal_error(ACE_LIB_TEXT ("Error parsing comment"), xmlenv); + this->report_fatal_error(ACE_TEXT ("Error parsing comment"), xmlenv); return -1; } break; case 0: - this->report_fatal_error (ACE_LIB_TEXT ("Unexpected EOF"), + this->report_fatal_error (ACE_TEXT ("Unexpected EOF"), xmlenv); return -1; default: - this->report_fatal_error (ACE_LIB_TEXT ("Invalid char. follows '<!' in markupdecl"), xmlenv); + this->report_fatal_error (ACE_TEXT ("Invalid char. follows '<!' in markupdecl"), xmlenv); return -1; } break; @@ -1079,11 +1079,11 @@ ACEXML_Parser::parse_internal_dtd (ACEXML_Env &xmlenv) break; case 0: - this->report_fatal_error (ACE_LIB_TEXT ("Unexpected EOF"), + this->report_fatal_error (ACE_TEXT ("Unexpected EOF"), xmlenv); return -1; default: - this->report_fatal_error (ACE_LIB_TEXT ("Invalid char. follows '<!' in markupdecl"), xmlenv); + this->report_fatal_error (ACE_TEXT ("Invalid char. follows '<!' in markupdecl"), xmlenv); return -1; } break; @@ -1097,12 +1097,12 @@ ACEXML_Parser::parse_internal_dtd (ACEXML_Env &xmlenv) case 0: // This may not be an error if we decide // to generalize this function to handle both // internal and external DTD definitions. - this->report_fatal_error (ACE_LIB_TEXT ("Unexpected EOF"), + this->report_fatal_error (ACE_TEXT ("Unexpected EOF"), xmlenv); return -1; default: - this->report_fatal_error (ACE_LIB_TEXT ("Expecting markupdecl or DecSep"), xmlenv); + this->report_fatal_error (ACE_TEXT ("Expecting markupdecl or DecSep"), xmlenv); return -1; }; @@ -1121,10 +1121,10 @@ ACEXML_Parser::parse_internal_dtd (ACEXML_Env &xmlenv) int ACEXML_Parser::parse_element_decl (ACEXML_Env &xmlenv) { - if ((this->parse_token (ACE_LIB_TEXT ("LEMENT")) < 0) || + if ((this->parse_token (ACE_TEXT ("LEMENT")) < 0) || this->skip_whitespace_count () == 0) { - this->report_fatal_error (ACE_LIB_TEXT ("Expecting keyword `ELEMENT'"), + this->report_fatal_error (ACE_TEXT ("Expecting keyword `ELEMENT'"), xmlenv); return -1; } @@ -1132,7 +1132,7 @@ ACEXML_Parser::parse_element_decl (ACEXML_Env &xmlenv) ACEXML_Char *element_name = this->read_name (); if (element_name == 0) { - this->report_fatal_error (ACE_LIB_TEXT ("Error reading element name while defining ELEMENT."), xmlenv); + this->report_fatal_error (ACE_TEXT ("Error reading element name while defining ELEMENT."), xmlenv); return -1; } @@ -1142,16 +1142,16 @@ ACEXML_Parser::parse_element_decl (ACEXML_Env &xmlenv) switch (nextch) { case 'E': // EMPTY - if (this->parse_token (ACE_LIB_TEXT ("EMPTY")) < 0) + if (this->parse_token (ACE_TEXT ("EMPTY")) < 0) { - this->report_fatal_error (ACE_LIB_TEXT ("Expecting keyword `EMPTY' in ELEMENT definition."), xmlenv); + this->report_fatal_error (ACE_TEXT ("Expecting keyword `EMPTY' in ELEMENT definition."), xmlenv); return -1; } break; case 'A': // ANY - if (this->parse_token (ACE_LIB_TEXT ("ANY")) < 0) + if (this->parse_token (ACE_TEXT ("ANY")) < 0) { - this->report_fatal_error (ACE_LIB_TEXT ("Expecting keyword `ANY' in ELEMENT definition."), xmlenv); + this->report_fatal_error (ACE_TEXT ("Expecting keyword `ANY' in ELEMENT definition."), xmlenv); return -1; } break; @@ -1160,12 +1160,12 @@ ACEXML_Parser::parse_element_decl (ACEXML_Env &xmlenv) ACEXML_CHECK_RETURN (-1); break; default: // error - this->report_fatal_error (ACE_LIB_TEXT ("Error reading ELEMENT definition."), xmlenv); + this->report_fatal_error (ACE_TEXT ("Error reading ELEMENT definition."), xmlenv); return -1; } if (this->skip_whitespace (0) != '>') { - this->report_fatal_error (ACE_LIB_TEXT ("Expecting '>' in ELEMENT definition."), xmlenv); + this->report_fatal_error (ACE_TEXT ("Expecting '>' in ELEMENT definition."), xmlenv); return -1; } return 0; @@ -1176,10 +1176,10 @@ ACEXML_Parser::parse_entity_decl (ACEXML_Env &xmlenv) { ACEXML_Char nextch; - if ((this->parse_token (ACE_LIB_TEXT ("NTITY")) < 0) || + if ((this->parse_token (ACE_TEXT ("NTITY")) < 0) || this->skip_whitespace_count (&nextch) == 0) { - this->report_fatal_error (ACE_LIB_TEXT ("Expecting keyword `ENTITY'"), + this->report_fatal_error (ACE_TEXT ("Expecting keyword `ENTITY'"), xmlenv); return -1; } @@ -1191,7 +1191,7 @@ ACEXML_Parser::parse_entity_decl (ACEXML_Env &xmlenv) this->get (); // consume the '%' if (this->skip_whitespace_count (&nextch) == 0) { - this->report_fatal_error (ACE_LIB_TEXT ("Can't use a reference when defining entity name"), xmlenv); + this->report_fatal_error (ACE_TEXT ("Can't use a reference when defining entity name"), xmlenv); return -1; } } @@ -1199,7 +1199,7 @@ ACEXML_Parser::parse_entity_decl (ACEXML_Env &xmlenv) ACEXML_Char *entity_name = this->read_name (); if (entity_name == 0) { - this->report_fatal_error (ACE_LIB_TEXT ("Error reading ENTITY name."), + this->report_fatal_error (ACE_TEXT ("Error reading ENTITY name."), xmlenv); return -1; } @@ -1212,7 +1212,7 @@ ACEXML_Parser::parse_entity_decl (ACEXML_Env &xmlenv) if (this->get_quoted_string (entity_value) != 0) { - this->report_fatal_error(ACE_LIB_TEXT("Error reading ENTITY value."), + this->report_fatal_error(ACE_TEXT("Error reading ENTITY value."), xmlenv); return -1; } @@ -1221,7 +1221,7 @@ ACEXML_Parser::parse_entity_decl (ACEXML_Env &xmlenv) { if (this->entities_.add_entity (entity_name, entity_value) != 0) { - this->report_fatal_error(ACE_LIB_TEXT("Error storing entity definition (duplicate definition?)"), xmlenv); + this->report_fatal_error(ACE_TEXT("Error storing entity definition (duplicate definition?)"), xmlenv); return -1; } } @@ -1240,7 +1240,7 @@ ACEXML_Parser::parse_entity_decl (ACEXML_Env &xmlenv) ACEXML_CHECK_RETURN (-1); if (systemid == 0) { - this->report_fatal_error(ACE_LIB_TEXT("Invalid ExternalID definition (system ID missing.)"), xmlenv); + this->report_fatal_error(ACE_TEXT("Invalid ExternalID definition (system ID missing.)"), xmlenv); return -1; } this->skip_whitespace_count (&nextch); @@ -1248,14 +1248,14 @@ ACEXML_Parser::parse_entity_decl (ACEXML_Env &xmlenv) { if (is_GEDecl == 0) { - this->report_fatal_error(ACE_LIB_TEXT("Unexpected keyword NDATA in PEDecl."), xmlenv); + this->report_fatal_error(ACE_TEXT("Unexpected keyword NDATA in PEDecl."), xmlenv); return -1; } - if ((this->parse_token (ACE_LIB_TEXT ("NDATA")) < 0) || + if ((this->parse_token (ACE_TEXT ("NDATA")) < 0) || this->skip_whitespace_count (&nextch) == 0) { - this->report_fatal_error(ACE_LIB_TEXT("Expecting keyword NDATA"), + this->report_fatal_error(ACE_TEXT("Expecting keyword NDATA"), xmlenv); return -1; } @@ -1272,16 +1272,16 @@ ACEXML_Parser::parse_entity_decl (ACEXML_Env &xmlenv) { // @@ Need to support external CharStream sources ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("ENTITY: (%s) "), + ACE_TEXT ("ENTITY: (%s) "), entity_name)); if (publicid == 0) ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("SYSTEM %s\n"), + ACE_TEXT ("SYSTEM %s\n"), systemid)); else ACE_DEBUG ((LM_DEBUG, - ACE_LIB_TEXT ("PUBLIC %s %s\n"), + ACE_TEXT ("PUBLIC %s %s\n"), publicid, systemid)); } } @@ -1289,7 +1289,7 @@ ACEXML_Parser::parse_entity_decl (ACEXML_Env &xmlenv) // End of ENTITY definition if (this->skip_whitespace (0) != '>') { - this->report_fatal_error(ACE_LIB_TEXT("Expecting end of ENTITY definition."), xmlenv); + this->report_fatal_error(ACE_TEXT("Expecting end of ENTITY definition."), xmlenv); return -1; } return 0; @@ -1298,10 +1298,10 @@ ACEXML_Parser::parse_entity_decl (ACEXML_Env &xmlenv) int ACEXML_Parser::parse_attlist_decl (ACEXML_Env &xmlenv) { - if ((this->parse_token (ACE_LIB_TEXT ("ATTLIST")) < 0) || + if ((this->parse_token (ACE_TEXT ("ATTLIST")) < 0) || this->skip_whitespace_count () == 0) { - this->report_fatal_error(ACE_LIB_TEXT("Expecting keyword `ATTLIST'"), + this->report_fatal_error(ACE_TEXT("Expecting keyword `ATTLIST'"), xmlenv); return -1; } @@ -1309,7 +1309,7 @@ ACEXML_Parser::parse_attlist_decl (ACEXML_Env &xmlenv) ACEXML_Char *element_name = this->read_name (); if (element_name == 0) { - this->report_fatal_error(ACE_LIB_TEXT("Error reading element name while defining ATTLIST."), xmlenv); + this->report_fatal_error(ACE_TEXT("Error reading element name while defining ATTLIST."), xmlenv); return -1; } @@ -1322,7 +1322,7 @@ ACEXML_Parser::parse_attlist_decl (ACEXML_Env &xmlenv) ACEXML_Char *att_name = this->read_name (nextch); if (att_name == 0) { - this->report_fatal_error(ACE_LIB_TEXT("Error reading attribute name while defining ATTLIST."), xmlenv); + this->report_fatal_error(ACE_TEXT("Error reading attribute name while defining ATTLIST."), xmlenv); return -1; } @@ -1344,10 +1344,10 @@ ACEXML_Parser::parse_attlist_decl (ACEXML_Env &xmlenv) switch (nextch) { case 'C': // CDATA - if ((this->parse_token (ACE_LIB_TEXT ("DATA")) < 0) || + if ((this->parse_token (ACE_TEXT ("DATA")) < 0) || this->skip_whitespace_count () == 0) { - this->report_fatal_error(ACE_LIB_TEXT("Expecting keyword `CDATA' while defining ATTLIST."), xmlenv); + this->report_fatal_error(ACE_TEXT("Expecting keyword `CDATA' while defining ATTLIST."), xmlenv); return -1; } // Else, we have successfully identified the type of the @@ -1363,7 +1363,7 @@ ACEXML_Parser::parse_attlist_decl (ACEXML_Env &xmlenv) // attribute as ID @@ Set up validator as such. break; } - if (this->parse_token (ACE_LIB_TEXT ("REF")) == 0) + if (this->parse_token (ACE_TEXT ("REF")) == 0) { if (this->skip_whitespace_count (&nextch) > 0) { @@ -1384,10 +1384,10 @@ ACEXML_Parser::parse_attlist_decl (ACEXML_Env &xmlenv) } } // Admittedly, this error message is not precise enough - this->report_fatal_error(ACE_LIB_TEXT("Expecting keyword `ID', `IDREF', or `IDREFS' while defining ATTLIST."), xmlenv); + this->report_fatal_error(ACE_TEXT("Expecting keyword `ID', `IDREF', or `IDREFS' while defining ATTLIST."), xmlenv); return -1; case 'E': // ENTITY or ENTITIES - if (this->parse_token (ACE_LIB_TEXT ("NTIT")) == 0) + if (this->parse_token (ACE_TEXT ("NTIT")) == 0) { nextch = this->get (); if (nextch == 'Y') @@ -1410,18 +1410,18 @@ ACEXML_Parser::parse_attlist_decl (ACEXML_Env &xmlenv) } } // Admittedly, this error message is not precise enough - this->report_fatal_error(ACE_LIB_TEXT("Expecting keyword `ENTITY', or `ENTITIES' while defining ATTLIST."), xmlenv); + this->report_fatal_error(ACE_TEXT("Expecting keyword `ENTITY', or `ENTITIES' while defining ATTLIST."), xmlenv); return -1; case 'N': // NMTOKEN, NMTOKENS, or, NOTATION nextch = this->get (); if (nextch != 'M' || nextch != 'O') { - this->report_fatal_error(ACE_LIB_TEXT("Expecting keyword `NMTOKEN', `NMTOKENS', or `NOTATION' while defining ATTLIST."), xmlenv); + this->report_fatal_error(ACE_TEXT("Expecting keyword `NMTOKEN', `NMTOKENS', or `NOTATION' while defining ATTLIST."), xmlenv); return -1; } if (nextch == 'M') { - if (this->parse_token (ACE_LIB_TEXT ("TOKEN")) == 0) + if (this->parse_token (ACE_TEXT ("TOKEN")) == 0) { if (this->skip_whitespace_count (&nextch) > 0) { @@ -1438,21 +1438,21 @@ ACEXML_Parser::parse_attlist_decl (ACEXML_Env &xmlenv) break; } } - this->report_fatal_error(ACE_LIB_TEXT("Expecting keyword `NMTOKEN' or `NMTOKENS' while defining ATTLIST."), xmlenv); + this->report_fatal_error(ACE_TEXT("Expecting keyword `NMTOKEN' or `NMTOKENS' while defining ATTLIST."), xmlenv); return -1; } else // NOTATION { - if ((this->parse_token (ACE_LIB_TEXT ("TATION")) < 0) || + if ((this->parse_token (ACE_TEXT ("TATION")) < 0) || this->skip_whitespace_count () == 0) { - this->report_fatal_error(ACE_LIB_TEXT("Expecting keyword `NOTATION' while defining ATTLIST."), xmlenv); + this->report_fatal_error(ACE_TEXT("Expecting keyword `NOTATION' while defining ATTLIST."), xmlenv); return -1; } if (this->get () != '(') { - this->report_fatal_error(ACE_LIB_TEXT("Expecting `(' following NOTATION while defining ATTLIST."), xmlenv); + this->report_fatal_error(ACE_TEXT("Expecting `(' following NOTATION while defining ATTLIST."), xmlenv); return -1; } @@ -1462,7 +1462,7 @@ ACEXML_Parser::parse_attlist_decl (ACEXML_Env &xmlenv) ACEXML_Char *notation_name = this->read_name (); if (notation_name == 0) { - this->report_fatal_error(ACE_LIB_TEXT("Error reading NOTATION name while defining ATTLIST."), xmlenv); + this->report_fatal_error(ACE_TEXT("Error reading NOTATION name while defining ATTLIST."), xmlenv); return -1; } // @@ get another notation name, set up validator as such @@ -1480,7 +1480,7 @@ ACEXML_Parser::parse_attlist_decl (ACEXML_Env &xmlenv) ACEXML_Char *token_name = this->read_name (); // @@ need a special read_nmtoken? if (token_name == 0) { - this->report_fatal_error(ACE_LIB_TEXT("Error reading enumerated nmtoken name while defining ATTLIST."), xmlenv); + this->report_fatal_error(ACE_TEXT("Error reading enumerated nmtoken name while defining ATTLIST."), xmlenv); return -1; } // @@ get another nmtoken, set up validator as such @@ -1492,7 +1492,7 @@ ACEXML_Parser::parse_attlist_decl (ACEXML_Env &xmlenv) break; default: { - this->report_fatal_error(ACE_LIB_TEXT("Invalid Attribute Type while defining ATTLIST."), xmlenv); + this->report_fatal_error(ACE_TEXT("Invalid Attribute Type while defining ATTLIST."), xmlenv); return -1; } ACE_NOTREACHED (break); @@ -1513,28 +1513,28 @@ ACEXML_Parser::parse_attlist_decl (ACEXML_Env &xmlenv) switch (this->get ()) { case 'R': - if (this->parse_token (ACE_LIB_TEXT ("EQUIRED")) < 0) + if (this->parse_token (ACE_TEXT ("EQUIRED")) < 0) { - this->report_fatal_error(ACE_LIB_TEXT("Expecting keyword `#REQUIRED' while defining ATTLIST."), xmlenv); + this->report_fatal_error(ACE_TEXT("Expecting keyword `#REQUIRED' while defining ATTLIST."), xmlenv); return -1; } // We now know this attribute is required // @@ Set up the validator as such. break; case 'I': - if (this->parse_token (ACE_LIB_TEXT ("MPLIED")) < 0) + if (this->parse_token (ACE_TEXT ("MPLIED")) < 0) { - this->report_fatal_error(ACE_LIB_TEXT("Expecting keyword `#IMPLIED' while defining ATTLIST."), xmlenv); + this->report_fatal_error(ACE_TEXT("Expecting keyword `#IMPLIED' while defining ATTLIST."), xmlenv); return -1; } // We now know this attribute is impleid. // @@ Set up the validator as such. break; case 'F': - if (this->parse_token (ACE_LIB_TEXT ("IXED")) < 0 || + if (this->parse_token (ACE_TEXT ("IXED")) < 0 || this->skip_whitespace_count () == 0) { - this->report_fatal_error(ACE_LIB_TEXT("Expecting keyword `#FIXED' while defining ATTLIST."), xmlenv); + this->report_fatal_error(ACE_TEXT("Expecting keyword `#FIXED' while defining ATTLIST."), xmlenv); return -1; } // We now know this attribute is fixed. @@ -1542,7 +1542,7 @@ ACEXML_Parser::parse_attlist_decl (ACEXML_Env &xmlenv) ACEXML_Char *fixed_attr; if (this->get_quoted_string (fixed_attr) != 0) { - this->report_fatal_error(ACE_LIB_TEXT("Error parsing `#FIXED' attribute value while defining ATTLIST."), xmlenv); + this->report_fatal_error(ACE_TEXT("Error parsing `#FIXED' attribute value while defining ATTLIST."), xmlenv); return -1; } // @@ set up validator @@ -1556,7 +1556,7 @@ ACEXML_Parser::parse_attlist_decl (ACEXML_Env &xmlenv) ACEXML_Char *fixed_attr; if (this->get_quoted_string (fixed_attr) != 0) { - this->report_fatal_error(ACE_LIB_TEXT("Error parsing `#FIXED' attribute value while defining ATTLIST."), xmlenv); + this->report_fatal_error(ACE_TEXT("Error parsing `#FIXED' attribute value while defining ATTLIST."), xmlenv); return -1; } // @@ set up validator @@ -1575,10 +1575,10 @@ ACEXML_Parser::parse_attlist_decl (ACEXML_Env &xmlenv) int ACEXML_Parser::parse_notation_decl (ACEXML_Env &xmlenv) { - if (this->parse_token (ACE_LIB_TEXT ("NOTATION")) < 0 || + if (this->parse_token (ACE_TEXT ("NOTATION")) < 0 || this->skip_whitespace_count () == 0) { - this->report_fatal_error(ACE_LIB_TEXT("Expecting keyword `NOTATION'"), + this->report_fatal_error(ACE_TEXT("Expecting keyword `NOTATION'"), xmlenv); return -1; } @@ -1586,7 +1586,7 @@ ACEXML_Parser::parse_notation_decl (ACEXML_Env &xmlenv) ACEXML_Char *notation = this->read_name (); if (notation == 0) { - this->report_fatal_error(ACE_LIB_TEXT("Invalid notation name."), xmlenv); + this->report_fatal_error(ACE_TEXT("Invalid notation name."), xmlenv); return -1; } @@ -1599,7 +1599,7 @@ ACEXML_Parser::parse_notation_decl (ACEXML_Env &xmlenv) if (this->get () != '>') { - this->report_fatal_error(ACE_LIB_TEXT("Expecting NOTATION closing '>'."), + this->report_fatal_error(ACE_TEXT("Expecting NOTATION closing '>'."), xmlenv); return -1; } @@ -1625,30 +1625,30 @@ ACEXML_Parser::parse_external_id_and_ref (ACEXML_Char *&publicId, switch (nextch) { case 'S': // External SYSTEM id. - if (this->parse_token (ACE_LIB_TEXT ("YSTEM")) < 0 || + if (this->parse_token (ACE_TEXT ("YSTEM")) < 0 || this->skip_whitespace_count () == 0) { - this->report_fatal_error(ACE_LIB_TEXT("Expecting keyword 'SYSTEM'"), + this->report_fatal_error(ACE_TEXT("Expecting keyword 'SYSTEM'"), xmlenv); return -1; } if (this->get_quoted_string (systemId) != 0) { - this->report_fatal_error(ACE_LIB_TEXT("Error while parsing SYSTEM literal for SYSTEM id."), xmlenv); + this->report_fatal_error(ACE_TEXT("Error while parsing SYSTEM literal for SYSTEM id."), xmlenv); return -1; } this->locator_.setSystemId (systemId); break; case 'P': // External PUBLIC id or previously defined PUBLIC id. - if (this->parse_token (ACE_LIB_TEXT ("UBLIC")) < 0 || + if (this->parse_token (ACE_TEXT ("UBLIC")) < 0 || this->skip_whitespace_count () == 0) { - this->report_fatal_error(ACE_LIB_TEXT("Expecting keyword 'PUBLIC'"), xmlenv); + this->report_fatal_error(ACE_TEXT("Expecting keyword 'PUBLIC'"), xmlenv); return -1; } if (this->get_quoted_string (publicId) != 0) { - this->report_fatal_error(ACE_LIB_TEXT("Error while parsing public literal for PUBLIC id."), xmlenv); + this->report_fatal_error(ACE_TEXT("Error while parsing public literal for PUBLIC id."), xmlenv); return -1; } this->locator_.setPublicId (publicId); @@ -1658,14 +1658,14 @@ ACEXML_Parser::parse_external_id_and_ref (ACEXML_Char *&publicId, { if (this->get_quoted_string (systemId) != 0) { - this->report_fatal_error(ACE_LIB_TEXT("Error while parsing system literal for PUBLIC id."), xmlenv); + this->report_fatal_error(ACE_TEXT("Error while parsing system literal for PUBLIC id."), xmlenv); return -1; } this->locator_.setSystemId (systemId); } break; default: - this->report_fatal_error(ACE_LIB_TEXT("Expecting either keyword `SYSTEM' or `PUBLIC'."), xmlenv); + this->report_fatal_error(ACE_TEXT("Expecting either keyword `SYSTEM' or `PUBLIC'."), xmlenv); return -1; } return 0; @@ -1683,9 +1683,9 @@ ACEXML_Parser::parse_children_definition (ACEXML_Env &xmlenv) switch (nextch) { case '#': // Mixed element, - if (this->parse_token (ACE_LIB_TEXT ("#PCDATA")) < 0) + if (this->parse_token (ACE_TEXT ("#PCDATA")) < 0) { - this->report_fatal_error(ACE_LIB_TEXT("Expecting keyword `#PCDATA' while defining an element."), xmlenv); + this->report_fatal_error(ACE_TEXT("Expecting keyword `#PCDATA' while defining an element."), xmlenv); return -1; } @@ -1695,7 +1695,7 @@ ACEXML_Parser::parse_children_definition (ACEXML_Env &xmlenv) { if (this->get () != '|') { - this->report_fatal_error(ACE_LIB_TEXT("Expecting end of Mixed section while defining an element."), xmlenv); + this->report_fatal_error(ACE_TEXT("Expecting end of Mixed section while defining an element."), xmlenv); return -1; } this->skip_whitespace_count (); @@ -1711,7 +1711,7 @@ ACEXML_Parser::parse_children_definition (ACEXML_Env &xmlenv) if (this->get () != ')' || (subelement_number && this->get () != '*')) { - this->report_fatal_error(ACE_LIB_TEXT("Expecting closing `)*' or ')' while defining an element."), xmlenv); + this->report_fatal_error(ACE_TEXT("Expecting closing `)*' or ')' while defining an element."), xmlenv); return -1; } // @@ close the element definition in the validator. @@ -1733,7 +1733,7 @@ ACEXML_Parser::parse_child (int skip_open_paren, if (skip_open_paren == 0 && this->get () != '(') { - this->report_fatal_error(ACE_LIB_TEXT("Expecting opening `(' while defining an element."), xmlenv); + this->report_fatal_error(ACE_TEXT("Expecting opening `(' while defining an element."), xmlenv); return -1; } @@ -1754,7 +1754,7 @@ ACEXML_Parser::parse_child (int skip_open_paren, ACEXML_Char *subelement = this->read_name (); if (subelement == 0) { - this->report_fatal_error(ACE_LIB_TEXT("Error reading sub-element name while defining an element."), xmlenv); + this->report_fatal_error(ACE_TEXT("Error reading sub-element name while defining an element."), xmlenv); return -1; } // @@ Inform validator of the new element here. @@ -1774,7 +1774,7 @@ ACEXML_Parser::parse_child (int skip_open_paren, case '|': break; default: - this->report_fatal_error(ACE_LIB_TEXT("Expecting `,', `|', or `)' while defining an element."), xmlenv); + this->report_fatal_error(ACE_TEXT("Expecting `,', `|', or `)' while defining an element."), xmlenv); return -1; } break; @@ -1788,13 +1788,13 @@ ACEXML_Parser::parse_child (int skip_open_paren, case ',': break; default: - this->report_fatal_error(ACE_LIB_TEXT("Expecting `,', `|', or `)'while defining an element."), xmlenv); + this->report_fatal_error(ACE_TEXT("Expecting `,', `|', or `)'while defining an element."), xmlenv); return -1; } case ')': break; default: - this->report_fatal_error(ACE_LIB_TEXT("Expecting `,', `|', or `)' while defining an element."), xmlenv); + this->report_fatal_error(ACE_TEXT("Expecting `,', `|', or `)' while defining an element."), xmlenv); return -1; } this->get (); // consume , | or ) @@ -1918,7 +1918,7 @@ ACEXML_Parser::get_quoted_string (ACEXML_Char *&str) if (this->parse_char_reference (buffer, 6) != 0) { // xmlenv.exception (new ACEXML_SAXParseException -// (ACE_LIB_TEXT ("CharRef does not resolves to a valid character"))); +// (ACE_TEXT ("CharRef does not resolves to a valid character"))); return -1; } charval.set (buffer, 0); @@ -1930,7 +1930,7 @@ ACEXML_Parser::get_quoted_string (ACEXML_Char *&str) if (replace == 0) { // xmlenv.exception (new ACEXML_SAXParseException - // (ACE_LIB_TEXT ("Undefined reference"))); + // (ACE_TEXT ("Undefined reference"))); return -1; } for (i = 0; i < replace->length (); ++i) @@ -1984,33 +1984,10 @@ ACEXML_Parser::report_prefix_mapping (const ACEXML_Char* prefix, { if (this->namespaces_) { + const char* temp = (name == 0) ? empty_string : prefix; if (start) - { - if (name == 0) - { - this->content_handler_->startPrefixMapping(empty_string, - uri, - xmlenv); - return; - } - else - { - this->content_handler_->startPrefixMapping (prefix, uri, xmlenv); - return; - } - } + this->content_handler_->startPrefixMapping (temp, uri, xmlenv); else - { - if (name == 0) - { - this->content_handler_->endPrefixMapping(empty_string, xmlenv); - return; - } - else - { - this->content_handler_->endPrefixMapping (prefix, xmlenv); - return; - } - } + this->content_handler_->endPrefixMapping(temp, xmlenv); } } |