diff options
100 files changed, 8464 insertions, 7510 deletions
diff --git a/ACEXML/ACEXML.dsw b/ACEXML/ACEXML.dsw index 096b5e0916d..4294abaa076 100644 --- a/ACEXML/ACEXML.dsw +++ b/ACEXML/ACEXML.dsw @@ -3,7 +3,34 @@ Microsoft Developer Studio Workspace File, Format Version 6.00 ###############################################################################
-Project: "ACEXML_Parser"=.\parser\parser\Parser.dsp - Package Owner=<4>
+Project: "ACEXML DLL"=common\ACEXML.dsp - Package Owner=<4>
+
+Package=<5>
+{{{
+}}}
+
+Package=<4>
+{{{
+}}}
+
+###############################################################################
+
+Project: "ACEXML_Parser DLL"=parser\parser\ACEXML_Parser.dsp - Package Owner=<4>
+
+Package=<5>
+{{{
+}}}
+
+Package=<4>
+{{{
+ Begin Project Dependency
+ Project_Dep_Name ACEXML DLL
+ End Project Dependency
+}}}
+
+###############################################################################
+
+Project: "ACEXML_XML_Svc_Conf_Parser DLL"=apps\svcconf\ACEXML_XML_Svc_Conf_Parser.dsp - Package Owner=<4>
Package=<5>
{{{
@@ -12,13 +39,16 @@ Package=<5> Package=<4>
{{{
Begin Project Dependency
- Project_Dep_Name XML_Common
+ Project_Dep_Name ACEXML_Parser DLL
+ End Project Dependency
+ Begin Project Dependency
+ Project_Dep_Name ACEXML DLL
End Project Dependency
}}}
###############################################################################
-Project: "Debug_Validator"=.\PARSER\DEBUG_VALIDATOR\Debug_Validator.dsp - Package Owner=<4>
+Project: "SAXPrint EXE"=examples\SAXPrint\SAXPrint.dsp - Package Owner=<4>
Package=<5>
{{{
@@ -27,13 +57,16 @@ Package=<5> Package=<4>
{{{
Begin Project Dependency
- Project_Dep_Name XML_Common
+ Project_Dep_Name ACEXML_Parser DLL
+ End Project Dependency
+ Begin Project Dependency
+ Project_Dep_Name ACEXML DLL
End Project Dependency
}}}
###############################################################################
-Project: "XML_Common"=.\COMMON\XML_Common.dsp - Package Owner=<4>
+Project: "Svcconf EXE"=examples\svcconf\Svcconf.dsp - Package Owner=<4>
Package=<5>
{{{
@@ -41,11 +74,20 @@ Package=<5> Package=<4>
{{{
+ Begin Project Dependency
+ Project_Dep_Name ACEXML_XML_Svc_Conf_Parser DLL
+ End Project Dependency
+ Begin Project Dependency
+ Project_Dep_Name ACEXML_Parser DLL
+ End Project Dependency
+ Begin Project Dependency
+ Project_Dep_Name ACEXML DLL
+ End Project Dependency
}}}
###############################################################################
-Project: "XML_Svc_Conf_Parser"=.\apps\svcconf\XML_Svc_Conf_Parser.dsp - Package Owner=<4>
+Project: "Transcoder_Test EXE"=tests\Transcoder_Test.dsp - Package Owner=<4>
Package=<5>
{{{
@@ -53,6 +95,66 @@ Package=<5> Package=<4>
{{{
+ Begin Project Dependency
+ Project_Dep_Name ACEXML_Parser DLL
+ End Project Dependency
+ Begin Project Dependency
+ Project_Dep_Name ACEXML DLL
+ End Project Dependency
+}}}
+
+###############################################################################
+
+Project: "NamespaceSupport_Test EXE"=tests\NamespaceSupport_Test.dsp - Package Owner=<4>
+
+Package=<5>
+{{{
+}}}
+
+Package=<4>
+{{{
+ Begin Project Dependency
+ Project_Dep_Name ACEXML_Parser DLL
+ End Project Dependency
+ Begin Project Dependency
+ Project_Dep_Name ACEXML DLL
+ End Project Dependency
+}}}
+
+###############################################################################
+
+Project: "HttpCharStream_Test EXE"=tests\HttpCharStream_Test.dsp - Package Owner=<4>
+
+Package=<5>
+{{{
+}}}
+
+Package=<4>
+{{{
+ Begin Project Dependency
+ Project_Dep_Name ACEXML_Parser DLL
+ End Project Dependency
+ Begin Project Dependency
+ Project_Dep_Name ACEXML DLL
+ End Project Dependency
+}}}
+
+###############################################################################
+
+Project: "ContentHandler_Test EXE"=tests\ContentHandler_Test.dsp - Package Owner=<4>
+
+Package=<5>
+{{{
+}}}
+
+Package=<4>
+{{{
+ Begin Project Dependency
+ Project_Dep_Name ACEXML_Parser DLL
+ End Project Dependency
+ Begin Project Dependency
+ Project_Dep_Name ACEXML DLL
+ End Project Dependency
}}}
###############################################################################
diff --git a/ACEXML/ACEXML.mwc b/ACEXML/ACEXML.mwc new file mode 100644 index 00000000000..3bcd3bd09c4 --- /dev/null +++ b/ACEXML/ACEXML.mwc @@ -0,0 +1,7 @@ +workspace (ACEXML) { + common + parser + apps + examples + tests +} diff --git a/ACEXML/ChangeLog b/ACEXML/ChangeLog new file mode 100644 index 00000000000..1dc57b02cba --- /dev/null +++ b/ACEXML/ChangeLog @@ -0,0 +1,515 @@ +Thu May 29 22:03:40 2003 Krishnakumar B <kitty@spam.invalid.domain> + + * ACEXML/ACEXML.mwc: + * ACEXML/ChangeLog: + * ACEXML/apps/svcconf/ACEXML_XML_Svc_Conf_Parser.dsp: + * ACEXML/apps/svcconf/Makefile.ACEXML_XML_Svc_Conf_Parser: + * ACEXML/apps/svcconf/Makefile.ACEXML_XML_Svc_Conf_Parser.bor: + * ACEXML/common/ACEXML.dsp: + * ACEXML/common/Makefile.ACEXML: + * ACEXML/common/Makefile.ACEXML.bor: + * ACEXML/examples/SAXPrint/Makefile.SAXPrint: + * ACEXML/examples/SAXPrint/Makefile.SAXPrint.bor: + * ACEXML/examples/svcconf/Makefile: + * ACEXML/examples/svcconf/Makefile.Svcconf: + * ACEXML/examples/svcconf/Makefile.Svcconf.bor: + * ACEXML/examples/svcconf/Svcconf.mpc: + * ACEXML/parser/parser/ACEXML_Parser.dsp: + * ACEXML/parser/parser/Makefile.ACEXML_Parser: + * ACEXML/parser/parser/Makefile.ACEXML_Parser.bor: + * ACEXML/parser/parser/Makefile.Parser: + * ACEXML/tests/Makefile.ContentHandler_Test.bor: + * ACEXML/tests/Makefile.HttpCharStream_Test: + * ACEXML/tests/Makefile.HttpCharStream_Test.bor: + * ACEXML/tests/Makefile.NamespaceSupport_Test: + * ACEXML/tests/Makefile.NamespaceSupport_Test.bor: + * ACEXML/tests/Makefile.Transcoder_Test: + * ACEXML/tests/Makefile.Transcoder_Test.bor: + + New files to build ACEXML generated using MPC. + + * ACEXML/apps/svcconf/svcconf.dtd: + + Moved the DTD from a hidden location to a prominent one. + + * ACEXML/examples/SAXPrint/namespaces.xml: + + New file to test namespace support. + + * ACEXML/common/ZipCharStream.cpp: + * ACEXML/common/ZipCharStream.h: + + New files to support reading files from within a ZIP archive as + a stream. + + * ACEXML/parser/parser/ParserContext.cpp: + * ACEXML/parser/parser/ParserContext.h: + * ACEXML/parser/parser/ParserContext.inl: + + New files to support a per stream context encountered when + parsing references. + + * ACEXML/parser/parser/ParserInternals.cpp: + * ACEXML/parser/parser/ParserInternals.h: + + Move some common functions from Parser.cpp to these files. + + * ACEXML/ACEXML.dsw: + * ACEXML/Makefile: + * ACEXML/Makefile.bor: + * ACEXML/apps/svcconf/Makefile: + * ACEXML/apps/svcconf/Makefile.bor: + * ACEXML/common/Makefile: + * ACEXML/common/Makefile.bor: + * ACEXML/examples/SAXPrint/Makefile: + * ACEXML/examples/SAXPrint/Makefile.bor: + * ACEXML/examples/SAXPrint/SAXPrint.dsp: + * ACEXML/examples/SAXPrint/SAXPrint.mpc: + * ACEXML/examples/svcconf/Makefile.bor: + * ACEXML/examples/svcconf/Svcconf.dsp: + * ACEXML/parser/parser/Makefile: + * ACEXML/parser/parser/Makefile.bor: + * ACEXML/tests/ContentHandler_Test.cpp: + * ACEXML/tests/ContentHandler_Test.dsp: + * ACEXML/tests/HttpCharStream_Test.cpp: + * ACEXML/tests/HttpCharStream_Test.dsp: + * ACEXML/tests/Makefile: + * ACEXML/tests/Makefile.bor: + * ACEXML/tests/NamespaceSupport_Test.dsp: + * ACEXML/tests/Transcoder_Test.dsp: + + Build related files changed with the introduction of MPC to + build ACEXML. + + * ACEXML/examples/SAXPrint/ns.svc.conf.xml: + * ACEXML/examples/SAXPrint/svc.conf.xml: + + New files to test specific features of the parser. + + * ACEXML/apps/svcconf/Svcconf.cpp: + * ACEXML/common/Attributes.h: + * ACEXML/common/Attributes_Def_Builder.h: + * ACEXML/common/CharStream.h: + * ACEXML/common/DefaultHandler.cpp: + * ACEXML/common/Encoding.cpp: + * ACEXML/common/Encoding.h: + * ACEXML/common/Exception.cpp: + * ACEXML/common/FileCharStream.cpp: + * ACEXML/common/FileCharStream.h: + * ACEXML/common/HttpCharStream.cpp: + * ACEXML/common/HttpCharStream.h: + * ACEXML/common/InputSource.cpp: + * ACEXML/common/InputSource.h: + * ACEXML/common/LocatorImpl.cpp: + * ACEXML/common/LocatorImpl.h: + * ACEXML/common/Mem_Map_Stream.cpp: + * ACEXML/common/NamespaceSupport.cpp: + * ACEXML/common/NamespaceSupport.h: + * ACEXML/common/SAXExceptions.cpp: + * ACEXML/common/StrCharStream.cpp: + * ACEXML/common/StrCharStream.h: + * ACEXML/common/StreamFactory.cpp: + * ACEXML/common/Transcode.cpp: + * ACEXML/common/Transcode.h: + * ACEXML/common/Transcode.i: + * ACEXML/examples/SAXPrint/Print_Handler.cpp: + * ACEXML/examples/SAXPrint/SAXPrint_Handler.cpp: + * ACEXML/examples/SAXPrint/main.cpp: + * ACEXML/examples/svcconf/main.cpp: + * ACEXML/parser/parser/Parser.cpp: + * ACEXML/parser/parser/Parser.h: + * ACEXML/parser/parser/Parser.i: + * ACEXML/parser/parser/Entity_Manager.cpp: + * ACEXML/parser/parser/Entity_Manager.h: + * ACEXML/parser/parser/Entity_Manager.i: + + Merge from the Validator branch. It is not close to conformance + related to Validation but is quite stable as a parser which + recognizes the complete XML grammar. + +Fri Jan 24 20:28:22 2003 Krishnakumar B <kitty@insanely.long.id.truncated> + + * parser/parser/Parser.cpp (pop_context): Bail out if there is + only one element on the context stack. Bad things [TM] will happen + if we pop the only context available. + +Mon Nov 25 04:25:15 2002 Krishnakumar B <kitty@cs.wustl.edu> + + * parser/parser/Parser.cpp (reset): + * parser/parser/Parser.h: + + Fixed a bunch of compilation errors. Removed unnecessary + creation and destroyal of ACEXML_Strings which seems to speed up + the parser quite a bit. + + * examples/SAXPrint/SAXPrint_Handler.cpp: + * examples/SAXPrint/main.cpp: + + Don't report startPrefixMapping() and endPrefixMapping() as they + obstruct the pretty-printing of SAXPrint. They are bogus anyway. + +Wed Nov 20 22:58:12 2002 Krishnakumar B <kitty@cs.wustl.edu> + + * parser/parser/Parser.cpp (parse_char_reference): + + Fixed stupid thinko in conditional parsing of a hex character + reference. + + * common/Mem_Map_Stream.cpp: + + We can use the old way of fetching on-demand and don't need to + use a while loop. + + * common/NamespaceSupport.cpp: + + Fixed a long-standing bug with core dumping. With these changes, + we are able to parse the XML specification itself. Is this + called Meta or what ? + +Wed Nov 20 20:44:56 2002 Krishnakumar B <kitty@cs.wustl.edu> + + * common/Mem_Map_Stream.cpp (grow_file_and_remap): + + Fixed bug where we were trying to remap two different files at + the same location without closing the first. + + * common/HttpCharStream.cpp (get_url): + + Don't try to parse an empty file. Removes a nasty SIGSEGV. + +Wed Nov 20 01:06:26 2002 Krishnakumar B <kitty@cs.wustl.edu> + + * common/Mem_Map_Stream.cpp: + + Minor indenting changes. + + * tests/HttpCharStream_Test.cpp: + + Modified test to show bug in ACE_File_Addr. + +Tue Nov 19 20:46:35 2002 Krishnakumar B <kitty@cs.wustl.edu> + + * examples/SAXPrint/Print_Handler.cpp (warning): + + Missed syncing the function prototypes last time. + +Tue Nov 19 20:18:09 2002 Krishnakumar B <kitty@cs.wustl.edu> + + * parser/parser/Parser.h: + * parser/parser/Parser.cpp (normalize_systemid): + + Fix an off-by-one error in normalization. The document's base + URI is never empty. Now we parse relative document URI + correctly. + + Implement the previously unimplemented parsing from a systemId. + + * common/InputSource.cpp: + * common/InputSource.h: + + Implement creating an InputSource from a systemId. + + * common/CharStream.h: + + Added a new method getSystemId(). + + * common/FileCharStream.cpp: + * common/FileCharStream.h: + * common/HttpCharStream.cpp: + * common/HttpCharStream.h: + * common/ZipCharStream.cpp: + * common/ZipCharStream.h: + * common/StrCharStream.cpp: + * common/StrCharStream.h: + + Added implementation for getSystemId(). + + * examples/SAXPrint/Print_Handler.cpp: + * examples/SAXPrint/SAXPrint_Handler.cpp: + + Synched up the printing of exception messages. + + * examples/SAXPrint/main.cpp: + + Fixed broken internal string version of a sample XML file. + +Tue Nov 19 15:02:06 2002 Krishnakumar B <kitty@cs.wustl.edu> + + * apps/svcconf/XML_Svc_Conf_Parser.dsp: + * common/XML_Common.dsp: + * examples/SAXPrint/SAXPrint.dsp: + * parser/debug_validator/Debug_Validator.dsp: + * parser/parser/Parser.dsp: + + Modified to accomodate zlib and zziplig. Will probably change + before the merge. + + * parser/parser/Parser.cpp: + + Try to parse external DTD only if validation is required. + +Mon Nov 18 22:29:39 2002 Krishnakumar B <kitty@cs.wustl.edu> + + * ACEXML/Makefile: + + Deleted this file in the previous check-in. Re-add it. + +Mon Nov 18 22:19:47 2002 Krishnakumar B <kitty@cs.wustl.edu> + + * ACEXML/common/common.mpc: + * ACEXML/parser/parser/parser.mpc: + * ACEXML/parser/debug_validator/validator.mpc: + * ACEXML/apps/svcconf/svcconf.mpc: + * ACEXML/examples/svcconf/Svcconf.mpc: + * ACEXML/examples/SAXPrint/saxprint.mpc: + * ACEXML/tests/tests.mpc: + * ACEXML/ACEXML.mwc: + + New MPC files and Workspace file. + + * ACEXML/common/Makefile.XML_Common: + * ACEXML/apps/svcconf/Makefile.XML_Svc_Conf_Parser: + * ACEXML/parser/parser/Makefile.Parser: + * ACEXML/parser/debug_validator/Makefile.Validator: + * ACEXML/examples/SAXPrint/Makefile.SAXPrint: + * ACEXML/examples/svcconf/Makefile.Svcconf: + * ACEXML/tests/Makefile.HttpCharStream_Test: + * ACEXML/tests/Makefile.NamespaceSupport_Test: + * ACEXML/tests/Makefile.Transcoder_Test: + + New Makefiles generated by MPC. + + * ACEXML/common/Makefile: + * ACEXML/parser/parser/Makefile: + * ACEXML/parser/Makefile: + * ACEXML/examples/Makefile: + * ACEXML/apps/Makefile: + * ACEXML/apps/svcconf/Makefile: + * ACEXML/examples/SAXPrint/Makefile: + * ACEXML/tests/Makefile: + + Removed old Makefiles. + + * ACEXML/parser/parser/Parser.cpp: + * ACEXML/common/StreamFactory.cpp: + * ACEXML/common/ZipCharStream.cpp: + * ACEXML/common/ZipCharStream.h: + + Fixed compilation errors. + +Mon Nov 18 20:30:30 2002 Krishnakumar B <kitty@cs.wustl.edu> + + * ACEXML/common/CharStream.h: + * ACEXML/common/Encoding.cpp: + * ACEXML/common/FileCharStream.cpp: + * ACEXML/common/FileCharStream.h: + * ACEXML/common/StrCharStream.cpp: + * ACEXML/common/StrCharStream.h: + * ACEXML/common/HttpCharStream.cpp: + * ACEXML/common/HttpCharStream.h: + + Fixed a number of minor typos and debugging statements. + + * ACEXML/common/LocatorImpl.cpp: Check for a valid string before + assigning it to the new Locator. + + * ACEXML/common/NamespaceSupport.cpp: + + Make sure that we don't have a null prefix before trying to + dereference the prefix. + + * ACEXML/common/ZipCharStream.cpp: + * ACEXML/common/ZipCharStream.h: + + New stream which reads files from a ZIP archive. + + * ACEXML/common/StreamFactory.cpp: + + Modified to accomodate ZipCharStream. + + * ACEXML/examples/SAXPrint/Print_Handler.cpp: + * ACEXML/examples/SAXPrint/SAXPrint_Handler.cpp: + * ACEXML/examples/SAXPrint/main.cpp: + + Commented out a lot of unnecessary debug statements. + + * ACEXML/parser/parser/Parser.cpp: + * ACEXML/parser/parser/Parser.h: + + Lots of bugfixes. Finally we parse the XML version of XHTML + specification without dumping core. + +Sat Nov 16 21:18:55 2002 Krishnakumar B <kitty@cs.wustl.edu> + + * ACEXML/parser/parser/Parser.cpp: + * ACEXML/parser/parser/Parser.h: + + More bugs fixed. Add support for parsing PE references within + attribute list declarations and clean up the same. Add support + for parsing PE references within element declarations. + +Tue Nov 12 19:48:34 2002 Krishnakumar B <kitty@cs.wustl.edu> + + * ACEXML/parser/parser/ParserContext.cpp: + * ACEXML/parser/parser/ParserContext.h: + * ACEXML/parser/parser/ParserContext.inl: + + New files which hold the ParserContext needed to handle the + switching of input streams on the fly. + + * ACEXML/parser/parser/ParserInternals.cpp: + * ACEXML/parser/parser/ParserInternals.h: + + Moved some generic code from Parser.cpp to here. + + * ACEXML/apps/svcconf/Makefile: + * ACEXML/common/Makefile: + * ACEXML/parser/parser/Makefile: + + Updated dependencies. + + * ACEXML/common/Attributes_Def_Builder.h: + + No need to typedef in C++. + + * ACEXML/common/DefaultHandler.cpp: + + Minor typos. + + * ACEXML/common/Encoding.cpp: + + If auto-detection of encoding fails, assume that it is UTF-8. + + * ACEXML/common/Exception.cpp: + + Change the error message from ACE_DEBUG to ACE_ERROR. + + * ACEXML/common/FileCharStream.cpp: Handle BOM of UTF-8 in + addition to UTF-16. Cleanup unnecessary parens. + + * ACEXML/common/HttpCharStream.cpp: + * ACEXML/common/HttpCharStream.h: + + Add support for auto-detection of encoding. + + * ACEXML/common/InputSource.cpp: + * ACEXML/common/InputSource.h: + + Fixes for use with ACEXML_Parser_Context. + + * ACEXML/common/LocatorImpl.cpp: + * ACEXML/common/LocatorImpl.h: + + Fixed bug in copy constructor which resulted in locator + information not getting set properly. + + * ACEXML/common/NamespaceSupport.cpp: + * ACEXML/common/NamespaceSupport.h: + + Implement reset() method. + + * ACEXML/common/SAXExceptions.cpp: + + Change the error message from ACE_DEBUG to ACE_ERROR. + + * ACEXML/common/StrCharStream.cpp: + + Handle copying of bytes according to sizeof (ACE_WCHAR). + + * ACEXML/common/StreamFactory.cpp: Create the appropriate stream + given an URI. We don't try to normalize the URI here. It is done + in the Parser. + + * ACEXML/common/Transcode.cpp: + * ACEXML/common/Transcode.i: + + Moved some very big functions from .i to .cpp. + + * ACEXML/examples/SAXPrint/SAXPrint_Handler.cpp: + * ACEXML/examples/SAXPrint/main.cpp: + + Updates to reflect the new calling convention in the Parser. + + * ACEXML/parser/parser/Entity_Manager.cpp: + * ACEXML/parser/parser/Entity_Manager.h: + * ACEXML/parser/parser/Entity_Manager.i: + + Implemented support for resolving SYSTEM and PUBLIC ids from + the Entity_Manager. + + * ACEXML/parser/parser/Parser.cpp: + * ACEXML/parser/parser/Parser.h: + * ACEXML/parser/parser/Parser.i: + + Implemented support for external parameter and entity + references. Rewrote a lot of the basic parsing functionality to + adhere to the standard. Implment partial support for validation + of XML files. + + +Fri Oct 25 15:44:04 2002 Krishnakumar B <kitty@cs.wustl.edu> + + * ACEXML/parser/parser/Parser.i: Handle end-of-line as required by + the spec. Specifically any sequence of 0x0D or 0x0D 0x0A should + be normalized to a 0x0A before passing to the XML processor. + + * ACEXML/parser/parser/Parser.cpp: Remove checks for 0x0D as it is + handled tranparently now. + +Thu Oct 24 21:06:44 2002 Krishnakumar B <kitty@cs.wustl.edu> + + * ACEXML/common/NamespaceSupport.cpp: Define strings normally and + not as an array. + + * ACEXML/common/Attributes_Def_Builder.h: No need to typedef in C++. + +Thu Oct 24 01:52:46 2002 Krishnakumar B <kitty@cs.wustl.edu> + + * ACEXML\parser\parser\Parser.cpp: Moved out the declaration of + variables outside case labels. MSVC doesn't like it. + +Wed Oct 23 22:24:59 2002 Krishnakumar B <kitty@cs.wustl.edu> + + * ACEXML/parser/parser/Parser.cpp: Fixed a stupid thinko in array + initialization. + +Wed Oct 23 17:27:14 2002 Krishnakumar B <kitty@cs.wustl.edu> + + * ACEXML/common/Encoding.cpp: + * ACEXML/common/Encoding.h: + + Use UTF-16 instead of UTF-16LE/UTF-16BE as the specification + doesn't require mentioning the endianness of the input. + + * ACEXML/common/Transcode.h: Fixed some minor typos. + + * ACEXML/examples/SAXPrint/namespaces.xml: New file which tests + out the namespaces feature much better. + + * ACEXML/apps/svcconf/Makefile: + * ACEXML/parser/parser/Makefile: + + Updated dependencies. + + * ACEXML/parser/parser/ParserErrors.h: New file which contains the + error codes of all the error spit out by the parser. + + * ACEXML/examples/SAXPrint/Print_Handler.cpp: + * ACEXML/examples/SAXPrint/SAXPrint_Handler.cpp: + + Make sure that the characters() function describes the arguments + as start and length instead of start and end. + + * ACEXML/parser/parser/Parser.dsp: Added ParserErrors.h to the + project file. + + * ACEXML/parser/parser/Parser.cpp: + * ACEXML/parser/parser/Parser.h: + + Use minor codes when reporting error in the parser. This cleans + up a lot of repeated error messages and indenting so that we + don't need to spill over 80 columns and have a standardized way + of reporting errors. Rewrote parse_cdata() so that is is much + simpler. Removed try_grow_cdata() as it is no longer needed. + Handle the case when the parser was accepting invalid character + references(). diff --git a/ACEXML/Makefile b/ACEXML/Makefile index ccba2b77d1c..e0454a993dd 100644 --- a/ACEXML/Makefile +++ b/ACEXML/Makefile @@ -1,21 +1,34 @@ +# $Id$ #---------------------------------------------------------------------------- -# $Id$ -# -# Makefile for the client programs that test the ACE network services +# GNU ACE Workspace #---------------------------------------------------------------------------- -DIRS = common \ - parser \ - apps \ - tests \ - examples - -#---------------------------------------------------------------------------- -# Include macros and targets -#---------------------------------------------------------------------------- - -include $(ACE_ROOT)/include/makeinclude/wrapper_macros.GNU include $(ACE_ROOT)/include/makeinclude/macros.GNU -include $(ACE_ROOT)/include/makeinclude/rules.common.GNU -include $(ACE_ROOT)/include/makeinclude/rules.nested.GNU -include $(ACE_ROOT)/include/makeinclude/rules.nolocal.GNU +TARGETS_NESTED := $(TARGETS_NESTED:.nested=) +MFILES = \ + common/Makefile.ACEXML \ + parser/parser/Makefile.ACEXML_Parser \ + apps/svcconf/Makefile.ACEXML_XML_Svc_Conf_Parser \ + examples/SAXPrint/Makefile.SAXPrint \ + examples/svcconf/Makefile.Svcconf \ + tests/Makefile.Transcoder_Test \ + tests/Makefile.NamespaceSupport_Test \ + tests/Makefile.HttpCharStream_Test \ + tests/Makefile.ContentHandler_Test + +$(TARGETS_NESTED): +ifneq (Windows,$(findstring Windows,$(OS))) + @for file in $(MFILES); do \ + $(MAKE) -f `basename $$file` -C `dirname $$file` $(@); \ + done +else + -@cmd /c "$(MAKE) -f Makefile.ACEXML -C common $(@)" + -@cmd /c "$(MAKE) -f Makefile.ACEXML_Parser -C parser/parser $(@)" + -@cmd /c "$(MAKE) -f Makefile.ACEXML_XML_Svc_Conf_Parser -C apps/svcconf $(@)" + -@cmd /c "$(MAKE) -f Makefile.SAXPrint -C examples/SAXPrint $(@)" + -@cmd /c "$(MAKE) -f Makefile.Svcconf -C examples/svcconf $(@)" + -@cmd /c "$(MAKE) -f Makefile.Transcoder_Test -C tests $(@)" + -@cmd /c "$(MAKE) -f Makefile.NamespaceSupport_Test -C tests $(@)" + -@cmd /c "$(MAKE) -f Makefile.HttpCharStream_Test -C tests $(@)" + -@cmd /c "$(MAKE) -f Makefile.ContentHandler_Test -C tests $(@)" +endif diff --git a/ACEXML/Makefile.bor b/ACEXML/Makefile.bor index 85ed6f2c300..fa36fd809e6 100644 --- a/ACEXML/Makefile.bor +++ b/ACEXML/Makefile.bor @@ -1,10 +1,124 @@ -# -# Makefile for building the ACE XML Library -# +#---------------------------------------------------------------------------- +# Borland Workspace +#---------------------------------------------------------------------------- -DIRS = \ - common \ - parser \ - apps +!include <$(ACE_ROOT)\include\makeinclude\make_flags.bor> -!include <$(ACE_ROOT)\include\makeinclude\recurse.bor> +all: + @cd common + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ACEXML.bor all + @cd ../ + @cd parser/parser + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ACEXML_Parser.bor all + @cd ../../ + @cd apps/svcconf + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ACEXML_XML_Svc_Conf_Parser.bor all + @cd ../../ + @cd examples/SAXPrint + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.SAXPrint.bor all + @cd ../../ + @cd examples/svcconf + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.Svcconf.bor all + @cd ../../ + @cd tests + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.Transcoder_Test.bor all + @cd ../ + @cd tests + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.NamespaceSupport_Test.bor all + @cd ../ + @cd tests + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.HttpCharStream_Test.bor all + @cd ../ + @cd tests + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ContentHandler_Test.bor all + @cd ../ + +clean: + @cd common + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ACEXML.bor clean + @cd ../ + @cd parser/parser + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ACEXML_Parser.bor clean + @cd ../../ + @cd apps/svcconf + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ACEXML_XML_Svc_Conf_Parser.bor clean + @cd ../../ + @cd examples/SAXPrint + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.SAXPrint.bor clean + @cd ../../ + @cd examples/svcconf + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.Svcconf.bor clean + @cd ../../ + @cd tests + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.Transcoder_Test.bor clean + @cd ../ + @cd tests + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.NamespaceSupport_Test.bor clean + @cd ../ + @cd tests + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.HttpCharStream_Test.bor clean + @cd ../ + @cd tests + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ContentHandler_Test.bor clean + @cd ../ + +realclean: + @cd common + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ACEXML.bor realclean + @cd ../ + @cd parser/parser + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ACEXML_Parser.bor realclean + @cd ../../ + @cd apps/svcconf + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ACEXML_XML_Svc_Conf_Parser.bor realclean + @cd ../../ + @cd examples/SAXPrint + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.SAXPrint.bor realclean + @cd ../../ + @cd examples/svcconf + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.Svcconf.bor realclean + @cd ../../ + @cd tests + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.Transcoder_Test.bor realclean + @cd ../ + @cd tests + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.NamespaceSupport_Test.bor realclean + @cd ../ + @cd tests + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.HttpCharStream_Test.bor realclean + @cd ../ + @cd tests + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ContentHandler_Test.bor realclean + @cd ../ + +install: + @cd common + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ACEXML.bor install + @cd ../ + @cd parser/parser + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ACEXML_Parser.bor install + @cd ../../ + @cd apps/svcconf + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ACEXML_XML_Svc_Conf_Parser.bor install + @cd ../../ + @cd examples/SAXPrint + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.SAXPrint.bor install + @cd ../../ + @cd examples/svcconf + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.Svcconf.bor install + @cd ../../ + @cd tests + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.Transcoder_Test.bor install + @cd ../ + @cd tests + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.NamespaceSupport_Test.bor install + @cd ../ + @cd tests + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.HttpCharStream_Test.bor install + @cd ../ + @cd tests + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ContentHandler_Test.bor install + @cd ../ + +regenerate: + D:\Perl\bin\perl.exe D:\ACE_wrappers\bin\mwc.pl -type borland -recurse diff --git a/ACEXML/apps/Makefile b/ACEXML/apps/Makefile deleted file mode 100644 index a5f05b99ae5..00000000000 --- a/ACEXML/apps/Makefile +++ /dev/null @@ -1,17 +0,0 @@ -#---------------------------------------------------------------------------- -# $Id$ -# -# Makefile for the client programs that test the ACE network services -#---------------------------------------------------------------------------- - -DIRS = svcconf - -#---------------------------------------------------------------------------- -# Include macros and targets -#---------------------------------------------------------------------------- - -include $(ACE_ROOT)/include/makeinclude/wrapper_macros.GNU -include $(ACE_ROOT)/include/makeinclude/macros.GNU -include $(ACE_ROOT)/include/makeinclude/rules.common.GNU -include $(ACE_ROOT)/include/makeinclude/rules.nested.GNU -include $(ACE_ROOT)/include/makeinclude/rules.nolocal.GNU diff --git a/ACEXML/apps/svcconf/ACEXML_XML_Svc_Conf_Parser.dsp b/ACEXML/apps/svcconf/ACEXML_XML_Svc_Conf_Parser.dsp new file mode 100644 index 00000000000..19e6da8b725 --- /dev/null +++ b/ACEXML/apps/svcconf/ACEXML_XML_Svc_Conf_Parser.dsp @@ -0,0 +1,111 @@ +# Microsoft Developer Studio Project File - Name="ACEXML_XML_Svc_Conf_Parser DLL" - Package Owner=<4>
+# Microsoft Developer Studio Generated Build File, Format Version 6.00
+# ** DO NOT EDIT **
+
+# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
+
+CFG=ACEXML_XML_Svc_Conf_Parser DLL - Win32 Debug
+!MESSAGE This is not a valid makefile. To build this project using NMAKE,
+!MESSAGE run the tool that generated this project file and specify the
+!MESSAGE nmake output type. You can then use the following command:
+!MESSAGE
+!MESSAGE NMAKE /f "ACEXML_XML_Svc_Conf_Parser.mak".
+!MESSAGE
+!MESSAGE You can specify a configuration when running NMAKE
+!MESSAGE by defining the macro CFG on the command line. For example:
+!MESSAGE
+!MESSAGE NMAKE /f "ACEXML_XML_Svc_Conf_Parser.mak" CFG="ACEXML_XML_Svc_Conf_Parser DLL - Win32 Debug"
+!MESSAGE
+!MESSAGE Possible choices for configuration are:
+!MESSAGE
+!MESSAGE "ACEXML_XML_Svc_Conf_Parser DLL - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library")
+!MESSAGE "ACEXML_XML_Svc_Conf_Parser DLL - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library")
+!MESSAGE
+
+# Begin Project
+# PROP AllowPerConfigDependencies 0
+# PROP Scc_ProjName ""
+# PROP Scc_LocalPath ""
+CPP=cl.exe
+RSC=rc.exe
+
+!IF "$(CFG)" == "ACEXML_XML_Svc_Conf_Parser DLL - Win32 Release"
+
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 0
+# PROP Output_Dir "."
+# PROP Intermediate_Dir "Release\ACEXML_XML_Svc_Conf_Parser"
+# PROP Ignore_Export_Lib 0
+# PROP Target_Dir ""
+# ADD CPP /nologo /W3 /GX /O2 /MD /Zi /GR /I "..\..\.." /D NDEBUG=1 /D WIN32=1 /D _WINDOWS=1 /FD /c
+# SUBTRACT CPP /YX
+# ADD RSC /l 0x409 /d NDEBUG=1 /i "..\..\.."
+BSC32=bscmake.exe
+# ADD BSC32 /nologo /o".\ACEXML_XML_Svc_Conf_Parser.bsc"
+LINK32=link.exe
+# ADD LINK32 advapi32.lib user32.lib /INCREMENTAL:NO ACEXML_Parser.lib ACEXML.lib ACE.lib /libpath:"..\..\..\ACEXML\common" /libpath:"..\..\..\ACEXML\parser\parser" /libpath:"..\..\..\ace" /nologo /version:5.3.1 /subsystem:windows /pdb:"..\..\..\bin\ACEXML_XML_Svc_Conf_Parser.pdb" /dll /machine:I386 /out:"..\..\..\bin\ACEXML_XML_Svc_Conf_Parser.dll"
+
+!ELSEIF "$(CFG)" == "ACEXML_XML_Svc_Conf_Parser DLL - Win32 Debug"
+
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 1
+# PROP Output_Dir "."
+# PROP Intermediate_Dir "Debug\ACEXML_XML_Svc_Conf_Parser"
+# PROP Ignore_Export_Lib 0
+# PROP Target_Dir ""
+# ADD CPP /nologo /W3 /Gm /GX /Zi /Od /MDd /GR /Gy /I "..\..\.." /D _DEBUG=1 /D WIN32=1 /D _WINDOWS=1 /FD /c
+# SUBTRACT CPP /Fr /YX
+# ADD RSC /l 0x409 /d _DEBUG=1 /i "..\..\.."
+BSC32=bscmake.exe
+# ADD BSC32 /nologo /o".\ACEXML_XML_Svc_Conf_Parser.bsc"
+LINK32=link.exe
+# ADD LINK32 advapi32.lib user32.lib /INCREMENTAL:NO ACEXML_Parserd.lib ACEXMLd.lib ACEd.lib /libpath:"..\..\..\ACEXML\common" /libpath:"..\..\..\ACEXML\parser\parser" /libpath:"..\..\..\ace" /nologo /version:5.3.1 /subsystem:windows /pdb:"..\..\..\bin\ACEXML_XML_Svc_Conf_Parserd.pdb" /dll /debug /machine:I386 /out:"..\..\..\bin\ACEXML_XML_Svc_Conf_Parserd.dll"
+
+!ENDIF
+
+# Begin Target
+
+# Name "ACEXML_XML_Svc_Conf_Parser DLL - Win32 Release"
+# Name "ACEXML_XML_Svc_Conf_Parser DLL - Win32 Debug"
+# Begin Group "Source Files"
+
+# PROP Default_Filter "cpp;cxx;c"
+# Begin Source File
+
+SOURCE=.\Svcconf.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\Svcconf_Handler.cpp
+# End Source File
+# End Group
+# Begin Group "Header Files"
+
+# PROP Default_Filter "h;hpp;hxx;hh"
+# Begin Source File
+
+SOURCE=.\Svcconf.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\Svcconf_Handler.h
+# End Source File
+# End Group
+# Begin Group "Inline Files"
+
+# PROP Default_Filter "i;inl"
+# Begin Source File
+
+SOURCE=.\Svcconf_Handler.i
+# End Source File
+# End Group
+# Begin Group "Documentation"
+
+# PROP Default_Filter ""
+# Begin Source File
+
+SOURCE=.\README
+# End Source File
+# End Group
+# End Target
+# End Project
diff --git a/ACEXML/apps/svcconf/Makefile b/ACEXML/apps/svcconf/Makefile index e291d22d14a..4afa1cd9673 100644 --- a/ACEXML/apps/svcconf/Makefile +++ b/ACEXML/apps/svcconf/Makefile @@ -1,400 +1,14 @@ +# $Id$ #---------------------------------------------------------------------------- -# $Id$ -# -# Makefile for the server-side ACE network services +# GNU ACE Workspace #---------------------------------------------------------------------------- -LIB = libACEXML_XML_Svc_Conf_Parser.a -SHLIB = libACEXML_XML_Svc_Conf_Parser.$(SOEXT) +include $(ACE_ROOT)/include/makeinclude/macros.GNU +TARGETS_NESTED := $(TARGETS_NESTED:.nested=) -FILES = Svcconf_Handler \ - Svcconf - -DEFS = $(addsuffix .h,$(FILES)) -LSRC = $(addsuffix .cpp,$(FILES)) - -LIBS += -lACEXML_Parser -lACEXML $(ACELIB) - -BUILD = $(VLIB) $(VSHLIB) - -#---------------------------------------------------------------------------- -# Include macros and targets -#---------------------------------------------------------------------------- - -include $(ACE_ROOT)/include/makeinclude/wrapper_macros.GNU -include $(ACE_ROOT)/include/makeinclude/macros.GNU -include $(ACE_ROOT)/include/makeinclude/rules.common.GNU -include $(ACE_ROOT)/include/makeinclude/rules.nonested.GNU -include $(ACE_ROOT)/include/makeinclude/rules.lib.GNU -include $(ACE_ROOT)/include/makeinclude/rules.local.GNU - -#---------------------------------------------------------------------------- -# Local targets -#---------------------------------------------------------------------------- - -#---------------------------------------------------------------------------- -# Dependencies -#---------------------------------------------------------------------------- -# DO NOT DELETE THIS LINE -- g++dep uses it. -# DO NOT PUT ANYTHING AFTER THIS LINE, IT WILL GO AWAY. - - -.obj/Svcconf_Handler.o .obj/Svcconf_Handler.so .shobj/Svcconf_Handler.o .shobj/Svcconf_Handler.so: Svcconf_Handler.cpp Svcconf_Handler.h \ - $(ACE_ROOT)/ACEXML/common/DefaultHandler.h \ - $(ACE_ROOT)/ace/pre.h \ - $(ACE_ROOT)/ACEXML/common/ACEXML_Export.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - $(ACE_ROOT)/ACEXML/common/ContentHandler.h \ - $(ACE_ROOT)/ACEXML/common/Env.h \ - $(ACE_ROOT)/ACEXML/common/XML_Macros.h \ - $(ACE_ROOT)/ace/Exception_Macros.h \ - $(ACE_ROOT)/ACEXML/common/Exception.h \ - $(ACE_ROOT)/ACEXML/common/XML_Types.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h \ - $(ACE_ROOT)/ace/Trace.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - $(ACE_ROOT)/ace/SString.i \ - $(ACE_ROOT)/ACEXML/common/Exception.i \ - $(ACE_ROOT)/ACEXML/common/Env.i \ - $(ACE_ROOT)/ACEXML/common/SAXExceptions.h \ - $(ACE_ROOT)/ACEXML/common/SAXExceptions.i \ - $(ACE_ROOT)/ACEXML/common/Locator.h \ - $(ACE_ROOT)/ACEXML/common/Attributes.h \ - $(ACE_ROOT)/ACEXML/common/DTDHandler.h \ - $(ACE_ROOT)/ACEXML/common/EntityResolver.h \ - $(ACE_ROOT)/ACEXML/common/InputSource.h \ - $(ACE_ROOT)/ACEXML/common/CharStream.h \ - $(ACE_ROOT)/ACEXML/common/ErrorHandler.h \ - $(ACE_ROOT)/ACEXML/common/DefaultHandler.i \ - $(ACE_ROOT)/ace/Service_Types.h \ - $(ACE_ROOT)/ace/Service_Object.h \ - $(ACE_ROOT)/ace/Shared_Object.h \ - $(ACE_ROOT)/ace/Shared_Object.i \ - $(ACE_ROOT)/ace/Svc_Conf_Tokens.h \ - $(ACE_ROOT)/ace/DLL.h \ - $(ACE_ROOT)/ace/Service_Object.i \ - $(ACE_ROOT)/ace/Service_Types.i \ - $(ACE_ROOT)/ace/Service_Config.h \ - $(ACE_ROOT)/ace/Unbounded_Queue.h \ - $(ACE_ROOT)/ace/Unbounded_Queue.inl \ - $(ACE_ROOT)/ace/Unbounded_Queue.cpp \ - $(ACE_ROOT)/ace/XML_Svc_Conf.h \ - $(ACE_ROOT)/ace/Service_Config.i \ - $(ACE_ROOT)/ace/Reactor.h \ - $(ACE_ROOT)/ace/Handle_Set.h \ - $(ACE_ROOT)/ace/Handle_Set.i \ - $(ACE_ROOT)/ace/Timer_Queue.h \ - $(ACE_ROOT)/ace/Timer_Queue_T.h \ - $(ACE_ROOT)/ace/Test_and_Set.h \ - $(ACE_ROOT)/ace/Test_and_Set.i \ - $(ACE_ROOT)/ace/Test_and_Set.cpp \ - $(ACE_ROOT)/ace/Timer_Queue_T.i \ - $(ACE_ROOT)/ace/Timer_Queue_T.cpp \ - $(ACE_ROOT)/ace/Reactor.i \ - $(ACE_ROOT)/ace/Reactor_Impl.h \ - $(ACE_ROOT)/ace/Service_Repository.h \ - $(ACE_ROOT)/ace/Service_Repository.i \ - $(ACE_ROOT)/ace/ARGV.h $(ACE_ROOT)/ace/ARGV.i \ - $(ACE_ROOT)/ace/Module.h \ - $(ACE_ROOT)/ace/Task_T.h \ - $(ACE_ROOT)/ace/Message_Queue.h \ - $(ACE_ROOT)/ace/Message_Block.h \ - $(ACE_ROOT)/ace/Message_Block.i \ - $(ACE_ROOT)/ace/Message_Block_T.h \ - $(ACE_ROOT)/ace/Message_Block_T.i \ - $(ACE_ROOT)/ace/Message_Block_T.cpp \ - $(ACE_ROOT)/ace/IO_Cntl_Msg.h \ - $(ACE_ROOT)/ace/Message_Queue_T.h \ - $(ACE_ROOT)/ace/Message_Queue_T.i \ - $(ACE_ROOT)/ace/Message_Queue_T.cpp \ - $(ACE_ROOT)/ace/Notification_Strategy.h \ - $(ACE_ROOT)/ace/Notification_Strategy.inl \ - $(ACE_ROOT)/ace/Message_Queue.i \ - $(ACE_ROOT)/ace/Task.h \ - $(ACE_ROOT)/ace/Thread_Manager.h \ - $(ACE_ROOT)/ace/Thread_Exit.h \ - $(ACE_ROOT)/ace/Thread_Control.h \ - $(ACE_ROOT)/ace/Thread_Control.inl \ - $(ACE_ROOT)/ace/Containers.h \ - $(ACE_ROOT)/ace/Containers.i \ - $(ACE_ROOT)/ace/Containers_T.h \ - $(ACE_ROOT)/ace/Array_Base.h \ - $(ACE_ROOT)/ace/Array_Base.inl \ - $(ACE_ROOT)/ace/Array_Base.cpp \ - $(ACE_ROOT)/ace/Containers_T.i \ - $(ACE_ROOT)/ace/Containers_T.cpp \ - $(ACE_ROOT)/ace/Singleton.h \ - $(ACE_ROOT)/ace/Singleton.i \ - $(ACE_ROOT)/ace/Singleton.cpp \ - $(ACE_ROOT)/ace/Object_Manager.h \ - $(ACE_ROOT)/ace/Object_Manager.i \ - $(ACE_ROOT)/ace/Managed_Object.h \ - $(ACE_ROOT)/ace/Managed_Object.i \ - $(ACE_ROOT)/ace/Managed_Object.cpp \ - $(ACE_ROOT)/ace/Framework_Component.h \ - $(ACE_ROOT)/ace/Framework_Component.inl \ - $(ACE_ROOT)/ace/Framework_Component_T.h \ - $(ACE_ROOT)/ace/Framework_Component_T.inl \ - $(ACE_ROOT)/ace/Framework_Component_T.cpp \ - $(ACE_ROOT)/ace/Thread_Manager.i \ - $(ACE_ROOT)/ace/Task.i $(ACE_ROOT)/ace/Task_T.i \ - $(ACE_ROOT)/ace/Task_T.cpp \ - $(ACE_ROOT)/ace/Module.i \ - $(ACE_ROOT)/ace/Module.cpp \ - $(ACE_ROOT)/ace/Stream_Modules.h \ - $(ACE_ROOT)/ace/Stream_Modules.cpp - -.obj/Svcconf.o .obj/Svcconf.so .shobj/Svcconf.o .shobj/Svcconf.so: Svcconf.cpp Svcconf.h $(ACE_ROOT)/ace/pre.h \ - $(ACE_ROOT)/ace/XML_Svc_Conf.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - $(ACE_ROOT)/ACEXML/parser/parser/Parser.h \ - $(ACE_ROOT)/ACEXML/parser/parser/Parser_export.h \ - $(ACE_ROOT)/ACEXML/common/XMLReader.h \ - $(ACE_ROOT)/ACEXML/common/ACEXML_Export.h \ - $(ACE_ROOT)/ACEXML/common/ContentHandler.h \ - $(ACE_ROOT)/ACEXML/common/Env.h \ - $(ACE_ROOT)/ACEXML/common/XML_Macros.h \ - $(ACE_ROOT)/ace/Exception_Macros.h \ - $(ACE_ROOT)/ACEXML/common/Exception.h \ - $(ACE_ROOT)/ACEXML/common/XML_Types.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h \ - $(ACE_ROOT)/ace/Trace.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - $(ACE_ROOT)/ace/SString.i \ - $(ACE_ROOT)/ACEXML/common/Exception.i \ - $(ACE_ROOT)/ACEXML/common/Env.i \ - $(ACE_ROOT)/ACEXML/common/SAXExceptions.h \ - $(ACE_ROOT)/ACEXML/common/SAXExceptions.i \ - $(ACE_ROOT)/ACEXML/common/Locator.h \ - $(ACE_ROOT)/ACEXML/common/Attributes.h \ - $(ACE_ROOT)/ACEXML/common/DTDHandler.h \ - $(ACE_ROOT)/ACEXML/common/EntityResolver.h \ - $(ACE_ROOT)/ACEXML/common/InputSource.h \ - $(ACE_ROOT)/ACEXML/common/CharStream.h \ - $(ACE_ROOT)/ACEXML/common/ErrorHandler.h \ - $(ACE_ROOT)/ACEXML/common/LocatorImpl.h \ - $(ACE_ROOT)/ACEXML/common/LocatorImpl.i \ - $(ACE_ROOT)/ACEXML/common/NamespaceSupport.h \ - $(ACE_ROOT)/ace/Functor.h \ - $(ACE_ROOT)/ace/Functor.i \ - $(ACE_ROOT)/ace/Functor_T.h \ - $(ACE_ROOT)/ace/Functor_T.i \ - $(ACE_ROOT)/ace/Functor_T.cpp \ - $(ACE_ROOT)/ace/Hash_Map_Manager.h \ - $(ACE_ROOT)/ace/Hash_Map_Manager_T.h \ - $(ACE_ROOT)/ace/Hash_Map_Manager_T.i \ - $(ACE_ROOT)/ace/Hash_Map_Manager_T.cpp \ - $(ACE_ROOT)/ace/Service_Config.h \ - $(ACE_ROOT)/ace/Unbounded_Queue.h \ - $(ACE_ROOT)/ace/Unbounded_Queue.inl \ - $(ACE_ROOT)/ace/Unbounded_Queue.cpp \ - $(ACE_ROOT)/ace/Service_Config.i \ - $(ACE_ROOT)/ace/Reactor.h \ - $(ACE_ROOT)/ace/Handle_Set.h \ - $(ACE_ROOT)/ace/Handle_Set.i \ - $(ACE_ROOT)/ace/Timer_Queue.h \ - $(ACE_ROOT)/ace/Timer_Queue_T.h \ - $(ACE_ROOT)/ace/Test_and_Set.h \ - $(ACE_ROOT)/ace/Test_and_Set.i \ - $(ACE_ROOT)/ace/Test_and_Set.cpp \ - $(ACE_ROOT)/ace/Timer_Queue_T.i \ - $(ACE_ROOT)/ace/Timer_Queue_T.cpp \ - $(ACE_ROOT)/ace/Reactor.i \ - $(ACE_ROOT)/ace/Reactor_Impl.h \ - $(ACE_ROOT)/ace/Svc_Conf_Tokens.h \ - $(ACE_ROOT)/ace/Containers_T.h \ - $(ACE_ROOT)/ace/Containers.h \ - $(ACE_ROOT)/ace/Containers.i \ - $(ACE_ROOT)/ace/Array_Base.h \ - $(ACE_ROOT)/ace/Array_Base.inl \ - $(ACE_ROOT)/ace/Array_Base.cpp \ - $(ACE_ROOT)/ace/Containers_T.i \ - $(ACE_ROOT)/ace/Containers_T.cpp \ - $(ACE_ROOT)/ACEXML/common/NamespaceSupport.i \ - $(ACE_ROOT)/ace/Obstack.h \ - $(ACE_ROOT)/ace/Obstack_T.h \ - $(ACE_ROOT)/ace/Obchunk.h \ - $(ACE_ROOT)/ace/Obchunk.i \ - $(ACE_ROOT)/ace/Obstack_T.i \ - $(ACE_ROOT)/ace/Obstack_T.cpp \ - $(ACE_ROOT)/ACEXML/parser/parser/Entity_Manager.h \ - $(ACE_ROOT)/ACEXML/parser/parser/Entity_Manager.i \ - $(ACE_ROOT)/ACEXML/parser/parser/Parser.i Svcconf_Handler.h \ - $(ACE_ROOT)/ACEXML/common/DefaultHandler.h \ - $(ACE_ROOT)/ACEXML/common/DefaultHandler.i \ - $(ACE_ROOT)/ace/Service_Types.h \ - $(ACE_ROOT)/ace/Service_Object.h \ - $(ACE_ROOT)/ace/Shared_Object.h \ - $(ACE_ROOT)/ace/Shared_Object.i \ - $(ACE_ROOT)/ace/DLL.h \ - $(ACE_ROOT)/ace/Service_Object.i \ - $(ACE_ROOT)/ace/Service_Types.i \ - $(ACE_ROOT)/ACEXML/common/FileCharStream.h \ - $(ACE_ROOT)/ACEXML/common/Encoding.h \ - $(ACE_ROOT)/ACEXML/common/StrCharStream.h - -# IF YOU PUT ANYTHING HERE IT WILL GO AWAY +$(TARGETS_NESTED): +ifneq (Windows,$(findstring Windows,$(OS))) + @$(MAKE) -f Makefile.ACEXML_XML_Svc_Conf_Parser -C . $(@); +else + -@cmd /c "$(MAKE) -f Makefile.ACEXML_XML_Svc_Conf_Parser -C . $(@)" +endif diff --git a/ACEXML/apps/svcconf/Makefile.ACEXML_XML_Svc_Conf_Parser b/ACEXML/apps/svcconf/Makefile.ACEXML_XML_Svc_Conf_Parser new file mode 100644 index 00000000000..92e6c77190d --- /dev/null +++ b/ACEXML/apps/svcconf/Makefile.ACEXML_XML_Svc_Conf_Parser @@ -0,0 +1,54 @@ +#---------------------------------------------------------------------------- +# GNU Makefile +#---------------------------------------------------------------------------- +MAKEFILE = Makefile.ACEXML_XML_Svc_Conf_Parser +DEPENDENCY_FILE = .depend.Makefile.ACEXML_XML_Svc_Conf_Parser +LIB_UNCHECKED = libACEXML_XML_Svc_Conf_Parser.a +SHLIB_UNCHECKED = libACEXML_XML_Svc_Conf_Parser.$(SOEXT) + + + +FILES = \ + Svcconf \ + Svcconf_Handler +#---------------------------------------------------------------------------- +# Include macros and targets +#---------------------------------------------------------------------------- + +LIB = $(LIB_UNCHECKED) +SHLIB = $(SHLIB_UNCHECKED) + +include $(ACE_ROOT)/include/makeinclude/wrapper_macros.GNU +LSRC = $(addsuffix .cpp, $(FILES)) +ACELIB = -lACE + +include $(ACE_ROOT)/include/makeinclude/macros.GNU +include $(ACE_ROOT)/include/makeinclude/rules.common.GNU +include $(ACE_ROOT)/include/makeinclude/rules.nonested.GNU +include $(ACE_ROOT)/include/makeinclude/rules.lib.GNU +include $(ACE_ROOT)/include/makeinclude/rules.local.GNU + +CPPFLAGS += -I../../.. + + +ifeq ($(static_libs),1) + ifneq ($(LIB),) + CPPFLAGS += -DACE_AS_STATIC_LIBS + endif +endif + + +LDFLAGS += -L../../../ACEXML/common -L../../../ACEXML/parser/parser -L../../../ace + + + +ACE_SHLIBS = -lACEXML_Parser -lACEXML $(ACELIB) +#---------------------------------------------------------------------------- +# Local targets +#---------------------------------------------------------------------------- + +realclean: clean +ifneq ($(GENERATED_DIRTY),) + -$(RM) -r $(GENERATED_DIRTY) +endif + diff --git a/ACEXML/apps/svcconf/Makefile.ACEXML_XML_Svc_Conf_Parser.bor b/ACEXML/apps/svcconf/Makefile.ACEXML_XML_Svc_Conf_Parser.bor new file mode 100644 index 00000000000..33ae7e0b8b1 --- /dev/null +++ b/ACEXML/apps/svcconf/Makefile.ACEXML_XML_Svc_Conf_Parser.bor @@ -0,0 +1,55 @@ +# Makefile for building the ACEXML_XML_Svc_Conf_Parser library with Borland C++ Builder + +NAME = ACEXML_XML_Svc_Conf_Parser + +NAME = ACEXML_XML_Svc_Conf_Parser + + +OBJFILES = \ + $(OBJDIR)\Svcconf.obj \ + $(OBJDIR)\Svcconf_Handler.obj + +EXTERNAL_LIBS = \ + \ + +LFLAGS = \ + -j..\..\..\ACEXML\common\$(CONFIG_SUBDIR) -j..\..\..\ACEXML\common \ + -L..\..\..\ACEXML\common\$(CONFIG_SUBDIR) -L..\..\..\ACEXML\common \ + -j..\..\..\ACEXML\parser\parser\$(CONFIG_SUBDIR) -j..\..\..\ACEXML\parser\parser \ + -L..\..\..\ACEXML\parser\parser\$(CONFIG_SUBDIR) -L..\..\..\ACEXML\parser\parser \ + -j..\..\..\ace\$(CONFIG_SUBDIR) -j..\..\..\ace \ + -L..\..\..\ace\$(CONFIG_SUBDIR) -L..\..\..\ace \ + -j$(CORE_BINDIR) \ + -L$(CORE_BINDIR) + +LIBFILES = \ + ACEXML_Parser$(LIB_DECORATOR).lib \ + ACEXML$(LIB_DECORATOR).lib \ + ACE$(LIB_DECORATOR).lib \ + $(EXTERNAL_LIBS) + + + +!ifdef STATIC +LIB_FLAGS = -DACE_AS_STATIC_LIBS +DLL_FLAGS = +!else +LIB_FLAGS = +DLL_FLAGS = +!endif + +CFLAGS = \ + -I..\..\.. \ + $(LIB_FLAGS) \ + $(DLL_FLAGS) + +CPPDIR = . + +INCLUDES = \ + Svcconf.h \ + Svcconf_Handler.h \ + Svcconf_Handler.i + +BASE_BINDIR = ..\..\..\bin + +!include <$(ACE_ROOT)\include\makeinclude\build_library.bor> diff --git a/ACEXML/apps/svcconf/Makefile.bor b/ACEXML/apps/svcconf/Makefile.bor index 0f40444b564..b088d5d48da 100644 --- a/ACEXML/apps/svcconf/Makefile.bor +++ b/ACEXML/apps/svcconf/Makefile.bor @@ -1,20 +1,20 @@ -# Makefile for building the parser +#---------------------------------------------------------------------------- +# Borland Workspace +#---------------------------------------------------------------------------- -NAME = ACEXML_XML_Svc_Conf_Parser +!include <$(ACE_ROOT)\include\makeinclude\make_flags.bor> -OBJFILES = \ - $(OBJDIR)\Svcconf.obj \ - $(OBJDIR)\Svcconf_Handler.obj +all: + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ACEXML_XML_Svc_Conf_Parser.bor all -CFLAGS = \ - $(ACE_CFLAGS) \ - $(ACE_XML_CFLAGS) +clean: + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ACEXML_XML_Svc_Conf_Parser.bor clean -CPPDIR = .;.. +realclean: + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ACEXML_XML_Svc_Conf_Parser.bor realclean -LIBFILES = \ - $(ACE_LIB) \ - $(ACE_XML_LIB) -# WE need both -lACEXML and -lACEXML_Parser here +install: + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ACEXML_XML_Svc_Conf_Parser.bor install -!include <$(ACE_ROOT)\include\makeinclude\build_core_library.bor> +regenerate: + D:\Perl\bin\perl.exe D:\ACE_wrappers\bin\mwc.pl -type borland -recurse diff --git a/ACEXML/apps/svcconf/Svcconf.cpp b/ACEXML/apps/svcconf/Svcconf.cpp index 12a6f3144fc..d35772008c2 100644 --- a/ACEXML/apps/svcconf/Svcconf.cpp +++ b/ACEXML/apps/svcconf/Svcconf.cpp @@ -86,9 +86,10 @@ ACEXML_Svcconf_Parser::parse_string (const ACE_TCHAR str[]) ACE_ERROR_RETURN ((LM_ERROR, "ACEXML_Svcconf_Parser: Can't parse a null string\n"), -1); ACEXML_StrCharStream *stm = 0; - ACE_NEW_RETURN (stm, - ACEXML_StrCharStream (str), - -1); + ACE_NEW_RETURN (stm, ACEXML_StrCharStream, -1); + if (stm->open (str, ACE_TEXT ("Svcconf")) < 0) + ACE_ERROR_RETURN ((LM_ERROR, "ACEXML_Svcconf_Parser: Unable to create " + "input stream.\n"), -1); this->input_stream_.setCharStream (stm); ACEXML_TRY_NEW_ENV diff --git a/ACEXML/apps/svcconf/XML_Svc_Conf_Parser.dsp b/ACEXML/apps/svcconf/XML_Svc_Conf_Parser.dsp deleted file mode 100644 index 7c48917d940..00000000000 --- a/ACEXML/apps/svcconf/XML_Svc_Conf_Parser.dsp +++ /dev/null @@ -1,121 +0,0 @@ -# Microsoft Developer Studio Project File - Name="XML_Svc_Conf_Parser" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=XML_Svc_Conf_Parser - Win32 Debug
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "XML_Svc_Conf_Parser.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "XML_Svc_Conf_Parser.mak" CFG="XML_Svc_Conf_Parser - Win32 Debug"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "XML_Svc_Conf_Parser - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "XML_Svc_Conf_Parser - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "XML_Svc_Conf_Parser - Win32 Release"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release"
-# PROP BASE Intermediate_Dir "Release"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir ""
-# PROP Intermediate_Dir "Release"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "XML_SVC_CONF_PARSER_EXPORTS" /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\..\.." /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /FD /c
-# SUBTRACT CPP /YX
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x409 /d "NDEBUG"
-# ADD RSC /l 0x409 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
-# ADD LINK32 ace.lib ACEXML.lib ACEXML_Parser.lib /nologo /dll /machine:I386 /out:"..\..\..\bin\ACEXML_XML_Svc_Conf_Parser.dll" /libpath:"..\..\..\ace" /libpath:"..\..\Common" /libpath:"..\..\parser\parser"
-
-!ELSEIF "$(CFG)" == "XML_Svc_Conf_Parser - Win32 Debug"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "XML_Svc_Conf_Parser___Win32_Debug"
-# PROP BASE Intermediate_Dir "XML_Svc_Conf_Parser___Win32_Debug"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir ""
-# PROP Intermediate_Dir "Debug"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "XML_SVC_CONF_PARSER_EXPORTS" /YX /FD /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /Zi /Od /I "..\..\.." /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /FD /c
-# SUBTRACT CPP /YX
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x409 /d "_DEBUG"
-# ADD RSC /l 0x409 /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 aced.lib ACEXMLd.lib ACEXML_Parserd.lib /nologo /dll /debug /machine:I386 /out:"..\..\..\bin\ACEXML_XML_Svc_Conf_Parserd.dll" /pdbtype:sept /libpath:"..\..\..\ace" /libpath:"..\..\Common" /libpath:"..\..\parser\parser"
-
-!ENDIF
-
-# Begin Target
-
-# Name "XML_Svc_Conf_Parser - Win32 Release"
-# Name "XML_Svc_Conf_Parser - Win32 Debug"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\Svcconf.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\Svcconf_Handler.cpp
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\Svcconf.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\Svcconf_Handler.h
-# End Source File
-# End Group
-# Begin Group "Resource Files"
-
-# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
-# End Group
-# End Target
-# End Project
diff --git a/ACEXML/examples/test_docs/svcconf.dtd b/ACEXML/apps/svcconf/svcconf.dtd index b9e6cc41c8e..b9e6cc41c8e 100644 --- a/ACEXML/examples/test_docs/svcconf.dtd +++ b/ACEXML/apps/svcconf/svcconf.dtd diff --git a/ACEXML/common/ACEXML.dsp b/ACEXML/common/ACEXML.dsp new file mode 100644 index 00000000000..83d2e43afcd --- /dev/null +++ b/ACEXML/common/ACEXML.dsp @@ -0,0 +1,359 @@ +# Microsoft Developer Studio Project File - Name="ACEXML DLL" - Package Owner=<4>
+# Microsoft Developer Studio Generated Build File, Format Version 6.00
+# ** DO NOT EDIT **
+
+# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
+
+CFG=ACEXML DLL - Win32 Debug
+!MESSAGE This is not a valid makefile. To build this project using NMAKE,
+!MESSAGE run the tool that generated this project file and specify the
+!MESSAGE nmake output type. You can then use the following command:
+!MESSAGE
+!MESSAGE NMAKE /f "ACEXML.mak".
+!MESSAGE
+!MESSAGE You can specify a configuration when running NMAKE
+!MESSAGE by defining the macro CFG on the command line. For example:
+!MESSAGE
+!MESSAGE NMAKE /f "ACEXML.mak" CFG="ACEXML DLL - Win32 Debug"
+!MESSAGE
+!MESSAGE Possible choices for configuration are:
+!MESSAGE
+!MESSAGE "ACEXML DLL - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library")
+!MESSAGE "ACEXML DLL - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library")
+!MESSAGE
+
+# Begin Project
+# PROP AllowPerConfigDependencies 0
+# PROP Scc_ProjName ""
+# PROP Scc_LocalPath ""
+CPP=cl.exe
+RSC=rc.exe
+
+!IF "$(CFG)" == "ACEXML DLL - Win32 Release"
+
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 0
+# PROP Output_Dir "."
+# PROP Intermediate_Dir "Release\ACEXML"
+# PROP Ignore_Export_Lib 0
+# PROP Target_Dir ""
+# ADD CPP /nologo /W3 /GX /O2 /MD /Zi /GR /I "..\.." /D NDEBUG=1 /D WIN32=1 /D _WINDOWS=1 /D ACEXML_BUILD_DLL=1 /FD /c
+# SUBTRACT CPP /YX
+# ADD RSC /l 0x409 /d NDEBUG=1 /i "..\.."
+BSC32=bscmake.exe
+# ADD BSC32 /nologo /o".\ACEXML.bsc"
+LINK32=link.exe
+# ADD LINK32 advapi32.lib user32.lib /INCREMENTAL:NO ACE.lib /libpath:"..\..\ace" /nologo /version:5.3.1 /subsystem:windows /pdb:"..\..\bin\ACEXML.pdb" /dll /machine:I386 /out:"..\..\bin\ACEXML.dll"
+
+!ELSEIF "$(CFG)" == "ACEXML DLL - Win32 Debug"
+
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 1
+# PROP Output_Dir "."
+# PROP Intermediate_Dir "Debug\ACEXML"
+# PROP Ignore_Export_Lib 0
+# PROP Target_Dir ""
+# ADD CPP /nologo /W3 /Gm /GX /Zi /Od /MDd /GR /Gy /I "..\.." /D _DEBUG=1 /D WIN32=1 /D _WINDOWS=1 /D ACEXML_BUILD_DLL=1 /FD /c
+# SUBTRACT CPP /Fr /YX
+# ADD RSC /l 0x409 /d _DEBUG=1 /i "..\.."
+BSC32=bscmake.exe
+# ADD BSC32 /nologo /o".\ACEXML.bsc"
+LINK32=link.exe
+# ADD LINK32 advapi32.lib user32.lib /INCREMENTAL:NO ACEd.lib /libpath:"..\..\ace" /nologo /version:5.3.1 /subsystem:windows /pdb:"..\..\bin\ACEXMLd.pdb" /dll /debug /machine:I386 /out:"..\..\bin\ACEXMLd.dll"
+
+!ENDIF
+
+# Begin Target
+
+# Name "ACEXML DLL - Win32 Release"
+# Name "ACEXML DLL - Win32 Debug"
+# Begin Group "Source Files"
+
+# PROP Default_Filter "cpp;cxx;c"
+# Begin Source File
+
+SOURCE=.\Attributes_Def_Builder.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\AttributesImpl.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\CharStream.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\DefaultHandler.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\DTD_Manager.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\Element_Def_Builder.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\Encoding.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\Env.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\Exception.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\FileCharStream.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\HttpCharStream.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\InputSource.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\LocatorImpl.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\Mem_Map_Stream.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\NamespaceSupport.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\SAXExceptions.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\StrCharStream.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\StreamFactory.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\Transcode.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\URL_Addr.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\Validator.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\XML_Codecs.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\XMLFilterImpl.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\ZipCharStream.cpp
+# End Source File
+# End Group
+# Begin Group "Header Files"
+
+# PROP Default_Filter "h;hpp;hxx;hh"
+# Begin Source File
+
+SOURCE=.\ACEXML_Export.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\Attributes.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\Attributes_Def_Builder.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\AttributesImpl.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\CharStream.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\ContentHandler.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\DefaultHandler.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\DTD_Manager.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\DTDHandler.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\Element_Def_Builder.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\Encoding.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\EntityResolver.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\Env.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\ErrorHandler.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\Exception.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\FileCharStream.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\HttpCharStream.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\InputSource.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\Locator.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\LocatorImpl.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\Mem_Map_Stream.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\NamespaceSupport.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\SAXExceptions.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\StrCharStream.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\StreamFactory.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\Transcode.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\URL_Addr.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\Validator.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\XML_Codecs.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\XML_Macros.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\XML_Types.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\XMLFilter.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\XMLFilterImpl.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\XMLReader.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\ZipCharStream.h
+# End Source File
+# End Group
+# Begin Group "Inline Files"
+
+# PROP Default_Filter "i;inl"
+# Begin Source File
+
+SOURCE=.\AttributesImpl.i
+# End Source File
+# Begin Source File
+
+SOURCE=.\DefaultHandler.i
+# End Source File
+# Begin Source File
+
+SOURCE=.\Env.i
+# End Source File
+# Begin Source File
+
+SOURCE=.\Exception.i
+# End Source File
+# Begin Source File
+
+SOURCE=.\LocatorImpl.i
+# End Source File
+# Begin Source File
+
+SOURCE=.\NamespaceSupport.i
+# End Source File
+# Begin Source File
+
+SOURCE=.\SAXExceptions.i
+# End Source File
+# Begin Source File
+
+SOURCE=.\Transcode.i
+# End Source File
+# Begin Source File
+
+SOURCE=.\URL_Addr.inl
+# End Source File
+# Begin Source File
+
+SOURCE=.\XMLFilterImpl.i
+# End Source File
+# End Group
+# End Target
+# End Project
diff --git a/ACEXML/common/Attributes_Def_Builder.h b/ACEXML/common/Attributes_Def_Builder.h index 26404fe6d86..ed7139bd2a3 100644 --- a/ACEXML/common/Attributes_Def_Builder.h +++ b/ACEXML/common/Attributes_Def_Builder.h @@ -39,7 +39,7 @@ public: typedef auto_ptr<ACEXML_Attribute_Def_Builder> VAR; - typedef enum { + enum ATT_TYPE { CDATA, ID, IDREF, @@ -51,14 +51,14 @@ public: NOTATION, ENUMERATION, ERROR_TYPE - } ATT_TYPE; + }; - typedef enum { + enum DEFAULT_DECL { REQUIRED, IMPLIED, FIXED, INVALID - } DEFAULT_DECL; + }; virtual ~ACEXML_Attribute_Def_Builder () = 0; diff --git a/ACEXML/common/CharStream.h b/ACEXML/common/CharStream.h index 1b5c199f527..00e58543acc 100644 --- a/ACEXML/common/CharStream.h +++ b/ACEXML/common/CharStream.h @@ -57,8 +57,7 @@ public: /** * Read the next batch of ACEXML_Char strings */ - virtual int read (ACEXML_Char *str, - size_t len) = 0; + virtual int read (ACEXML_Char *str, size_t len) = 0; /** * Peek the next ACEXML_Char in the CharStream. Return the @@ -71,6 +70,11 @@ public: */ virtual const ACEXML_Char *getEncoding (void) = 0; + /* + * Get the systemId for the underlying CharStream + */ + virtual const ACEXML_Char* getSystemId (void) = 0; + }; #include "ace/post.h" diff --git a/ACEXML/common/DefaultHandler.cpp b/ACEXML/common/DefaultHandler.cpp index f96e29d3cf3..60d2d783366 100644 --- a/ACEXML/common/DefaultHandler.cpp +++ b/ACEXML/common/DefaultHandler.cpp @@ -103,7 +103,7 @@ ACEXML_DefaultHandler::startPrefixMapping (const ACEXML_Char *, // No-op. } - // *** Methods inherit from ACEXML_DTDHandler. + // *** Methods inherited from ACEXML_DTDHandler. void ACEXML_DefaultHandler::notationDecl (const ACEXML_Char *, @@ -124,7 +124,7 @@ ACEXML_DefaultHandler::unparsedEntityDecl (const ACEXML_Char *, // No-op. } - // Methods inherit from ACEXML_EnitityResolver. + // Methods inherited from ACEXML_EntityResolver. ACEXML_InputSource * ACEXML_DefaultHandler::resolveEntity (const ACEXML_Char *, @@ -135,7 +135,7 @@ ACEXML_DefaultHandler::resolveEntity (const ACEXML_Char *, return 0; } - // Methods inherit from ACEXML_ErrorHandler. + // Methods inherited from ACEXML_ErrorHandler. /* * Receive notification of a recoverable error. diff --git a/ACEXML/common/Encoding.cpp b/ACEXML/common/Encoding.cpp index 7fe8811cdbd..c47ded83051 100644 --- a/ACEXML/common/Encoding.cpp +++ b/ACEXML/common/Encoding.cpp @@ -7,8 +7,8 @@ const ACEXML_Char* ACEXML_Encoding::encoding_names_[8] = { ACE_TEXT ("UCS-4LE"), ACE_TEXT ("UCS-4_2143"), ACE_TEXT ("UCS-4_3412"), - ACE_TEXT ("UTF-16BE"), - ACE_TEXT ("UTF-16LE"), + ACE_TEXT ("UTF-16"), + ACE_TEXT ("UTF-16"), ACE_TEXT ("UTF-8"), ACE_TEXT ("Unsupported Encoding") }; @@ -18,8 +18,8 @@ const ACEXML_UTF8 ACEXML_Encoding::byte_order_mark_[][4] = { { '\xFF', '\xFE', '\x00', '\x00' }, // UCS-4, little-endian (4321 order) { '\x00', '\x00', '\xFF', '\xFE' }, // UCS-4, unusual octet order (2143) { '\xFE', '\xFF', '\x00', '\x00' }, // UCS-4, unusual octet order (3412) - { '\xFE', '\xFF', '\xFF', '\xFF' }, // UTF-16, big-endian (3 & 4 ignored) - { '\xFF', '\xFE', '\xFF', '\xFF' }, // UTF-16, little-endian ( 3 & 4 ignored) + { '\xFE', '\xFF', '\xFF', '\xFF' }, // UTF-16, big-endian (3 & 4 != 0) + { '\xFF', '\xFE', '\xFF', '\xFF' }, // UTF-16, little-endian ( 3 & 4 != 0) { '\xEF', '\xBB', '\xBF', '\xFF' } // UTF-8 }; @@ -36,11 +36,13 @@ const ACEXML_UTF8 ACEXML_Encoding::magic_values_[][4] = { const ACEXML_Char* ACEXML_Encoding::get_encoding (const char* input) { - if (ACE_OS::memcmp (&ACEXML_Encoding::byte_order_mark_[ACEXML_Encoding::UTF16BE][0], input, 2) == 0) + if ((ACE_OS::memcmp (&ACEXML_Encoding::byte_order_mark_[ACEXML_Encoding::UTF16BE][0], input, 2) == 0) + && (input[2] != 0 || input[3] != 0)) // 3 & 4 should not be both zero return ACEXML_Encoding::encoding_names_[ACEXML_Encoding::UTF16BE]; - else if (ACE_OS::memcmp (&ACEXML_Encoding::byte_order_mark_[ACEXML_Encoding::UTF16LE][0], input, 2) == 0) + else if ((ACE_OS::memcmp (&ACEXML_Encoding::byte_order_mark_[ACEXML_Encoding::UTF16LE][0], input, 2) == 0) + && (input[2] != 0 || input[3] != 0)) // 3 & 4 should not be both zero return ACEXML_Encoding::encoding_names_[ACEXML_Encoding::UTF16LE]; - else if (ACE_OS::memcmp (&ACEXML_Encoding::byte_order_mark_[ACEXML_Encoding::UTF8][0], input, 4) == 0) + else if (ACE_OS::memcmp (&ACEXML_Encoding::byte_order_mark_[ACEXML_Encoding::UTF8][0], input, 3) == 0) return ACEXML_Encoding::encoding_names_[ACEXML_Encoding::UTF8]; else if (ACE_OS::memcmp (&ACEXML_Encoding::magic_values_[ACEXML_Encoding::UTF16BE][0], input, 4) == 0) return ACEXML_Encoding::encoding_names_[ACEXML_Encoding::UTF16BE]; @@ -49,5 +51,8 @@ ACEXML_Encoding::get_encoding (const char* input) else if (ACE_OS::memcmp (&ACEXML_Encoding::magic_values_[ACEXML_Encoding::UTF8][0], input, 4) == 0) return ACEXML_Encoding::encoding_names_[ACEXML_Encoding::UTF8]; else - return ACEXML_Encoding::encoding_names_[ACEXML_Encoding::OTHER]; + { + // ACE_ERROR ((LM_ERROR, "Unknown encoding. Assuming UTF-8\n")); + return ACEXML_Encoding::encoding_names_[ACEXML_Encoding::UTF8]; + } } diff --git a/ACEXML/common/Encoding.h b/ACEXML/common/Encoding.h index fc0917c0b91..9c334a3b602 100644 --- a/ACEXML/common/Encoding.h +++ b/ACEXML/common/Encoding.h @@ -36,14 +36,14 @@ class ACEXML_Export ACEXML_Encoding { public: enum { - UCS4BE = 0, - UCS4LE = 1, - UCS4_2143 = 2, - UCS4_3412 = 3, - UTF16BE = 4, - UTF16LE = 5, - UTF8 = 6, - OTHER = 7 + UCS4BE, + UCS4LE, + UCS4_2143, + UCS4_3412, + UTF16BE, + UTF16LE, + UTF8, + OTHER } ENCODING; static const ACEXML_Char* encoding_names_[8]; diff --git a/ACEXML/common/Exception.cpp b/ACEXML/common/Exception.cpp index 3086a8a7bfb..88b2a5709a7 100644 --- a/ACEXML/common/Exception.cpp +++ b/ACEXML/common/Exception.cpp @@ -45,7 +45,7 @@ ACEXML_Exception::is_a (const ACEXML_Char *name) void ACEXML_Exception::print (void) { - ACE_DEBUG ((LM_ERROR, + ACE_ERROR ((LM_ERROR, ACE_TEXT ("ACEXML: (%P|%t) EXCEPTION : %s\n"), this->exception_name_)); } diff --git a/ACEXML/common/FileCharStream.cpp b/ACEXML/common/FileCharStream.cpp index 7592d2f622a..cbee8018571 100644 --- a/ACEXML/common/FileCharStream.cpp +++ b/ACEXML/common/FileCharStream.cpp @@ -5,7 +5,7 @@ #include "ace/Log_Msg.h" ACEXML_FileCharStream::ACEXML_FileCharStream (void) - : filename_ (0), encoding_ (0), size_ (0), infile_ (NULL), peek_ (0) + : filename_ (0), encoding_ (0), size_ (0), infile_ (0), peek_ (0) { } @@ -24,7 +24,7 @@ ACEXML_FileCharStream::open (const ACEXML_Char *name) this->encoding_ = 0; this->infile_ = ACE_OS::fopen (name, ACE_TEXT ("r")); - if (this->infile_ == NULL) + if (this->infile_ == 0) return -1; ACE_stat statbuf; @@ -33,13 +33,15 @@ ACEXML_FileCharStream::open (const ACEXML_Char *name) this->size_ = statbuf.st_size; this->filename_ = ACE::strnew (name); - this->determine_encoding(); - return 0; + return this->determine_encoding(); } int ACEXML_FileCharStream::determine_encoding (void) { + if (this->infile_ == 0) + return -1; + char input[4]; int retval = 0; int i = 0; @@ -54,20 +56,20 @@ ACEXML_FileCharStream::determine_encoding (void) const ACEXML_Char* temp = ACEXML_Encoding::get_encoding (input); if (!temp) return -1; - if (ACE_OS::strcmp (temp, - ACEXML_Encoding::encoding_names_[ACEXML_Encoding::OTHER]) == 0) - return -1; else { this->encoding_ = ACE::strnew (temp); -// ACE_DEBUG ((LM_DEBUG, "File's encoding is %s\n", this->encoding_)); +// ACE_DEBUG ((LM_DEBUG, ACE_TEXT ("File's encoding is %s\n"), +// this->encoding_)); } // Move over the byte-order-mark if present. char ch; - for (int j = 0; j < 2; ++j) + for (int j = 0; j < 3; ++j) { - this->getchar_i (ch); - if (ch == '\xFF' || ch == '\xFE' || ch == '\xEF') + if (this->getchar_i (ch) < 0) + return -1; + if (ch == '\xFF' || ch == '\xFE' || ch == '\xEF' || ch == '\xBB' || + ch == '\xBF') continue; else { @@ -81,12 +83,17 @@ ACEXML_FileCharStream::determine_encoding (void) void ACEXML_FileCharStream::rewind() { + if (this->infile_ == 0) + return; ACE_OS::rewind (this->infile_); } int ACEXML_FileCharStream::available (void) { + if (this->infile_ == 0) + return -1; + long curr; if ((curr = ACE_OS::ftell (this->infile_)) < 0) return -1; @@ -96,10 +103,10 @@ ACEXML_FileCharStream::available (void) int ACEXML_FileCharStream::close (void) { - if (this->infile_ != NULL) + if (this->infile_ != 0) { ACE_OS::fclose (this->infile_); - this->infile_ = NULL; + this->infile_ = 0; } delete[] this->filename_; this->filename_ = 0; @@ -122,12 +129,18 @@ int ACEXML_FileCharStream::read (ACEXML_Char *str, size_t len) { - return ACE_static_cast (int, ACE_OS::fread (str, len, 1, this->infile_)); + if (this->infile_ == 0) + return -1; + + return ACE_static_cast (int, + ACE_OS::fread (str, sizeof (ACEXML_Char), len, this->infile_)); } int ACEXML_FileCharStream::get (ACEXML_Char& ch) { + if (this->infile_ == 0) + return -1; #if defined (ACE_USES_WCHAR) return this->get_i (ch); #else @@ -136,6 +149,21 @@ ACEXML_FileCharStream::get (ACEXML_Char& ch) #endif /* ACE_USES_WCHAR */ } +int +ACEXML_FileCharStream::peek (void) +{ + if (this->infile_ == 0) + return -1; +#if defined (ACE_USES_WCHAR) + return this->peek_i(); +#else + + ACEXML_Char ch = ACE_OS::fgetc (this->infile_); + ::ungetc (ch, this->infile_); + return ch; +#endif /* ACE_USES_WCHAR */ +} + #if defined (ACE_USES_WCHAR) int ACEXML_FileCharStream::get_i (ACEXML_Char& ch) @@ -166,24 +194,10 @@ ACEXML_FileCharStream::get_i (ACEXML_Char& ch) ch = 0; return -1; } - ch = (BE) ? (input[0] << 8) | input[1] : (input[1] << 8) | input[0]; + ch = BE ? input[0] << 8 | input[1] : input[1] << 8 | input[0]; return 0; } -#endif /* ACE_USES_WCHAR */ - -int -ACEXML_FileCharStream::peek (void) -{ -#if defined (ACE_USES_WCHAR) - return this->peek_i(); -#else - ACEXML_Char ch = ACE_OS::fgetc (this->infile_); - ::ungetc (ch, this->infile_); - return ch; -#endif /* ACE_USES_WCHAR */ -} -#if defined (ACE_USES_WCHAR) int ACEXML_FileCharStream::peek_i (void) { @@ -215,7 +229,7 @@ ACEXML_FileCharStream::peek_i (void) this->peek_ = 0; return -1; } - this->peek_ = (BE) ? (input[0] << 8) | input[1] : (input[1] << 8) | input[0]; + this->peek_ = BE ? input[0] << 8 | input[1] : input[1] << 8 | input[0]; return this->peek_; } #endif /* ACE_USES_WCHAR */ @@ -225,3 +239,9 @@ ACEXML_FileCharStream::getEncoding (void) { return this->encoding_; } + +const ACEXML_Char* +ACEXML_FileCharStream::getSystemId (void) +{ + return this->filename_; +} diff --git a/ACEXML/common/FileCharStream.h b/ACEXML/common/FileCharStream.h index d71792aac59..5e3293b40c3 100644 --- a/ACEXML/common/FileCharStream.h +++ b/ACEXML/common/FileCharStream.h @@ -54,7 +54,7 @@ public: /** * Read the next ACEXML_Char. Return -1 if we are not able to - * return an ACEXML_Char, 0 if EOS is reached, or 1 if succeed. + * return an ACEXML_Char, 0 if succees. */ virtual int get (ACEXML_Char& ch); @@ -82,18 +82,21 @@ public: virtual void rewind (void); /* - * Get the character encoding for a byte stream or URI. + * Get the character encoding for the file. */ virtual const ACEXML_Char *getEncoding (void); -protected: + /* + * Get the systemId for the underlying CharStream + */ + virtual const ACEXML_Char* getSystemId (void); + +private: /** Read the next character as a normal character. Return -1 if EOF is * reached, else return 0. */ - virtual int getchar_i (char& ch); - -private: + int getchar_i (char& ch); #if defined (ACE_USES_WCHAR) /** diff --git a/ACEXML/common/HttpCharStream.cpp b/ACEXML/common/HttpCharStream.cpp index fabd156852a..d6af4cc01c8 100644 --- a/ACEXML/common/HttpCharStream.cpp +++ b/ACEXML/common/HttpCharStream.cpp @@ -4,6 +4,7 @@ #include "ace/ace_wchar.h" #include "ace/Auto_Ptr.h" #include "ACEXML/common/HttpCharStream.h" +#include "ACEXML/common/Encoding.h" ACE_RCSID (common, HttpCharStream, "$Id$") @@ -72,7 +73,7 @@ ACEXML_HttpCharStream::open (const ACEXML_Char *url) this->close(); ACE_ERROR_RETURN ((LM_ERROR, "Server returned status %d : %s\n", result, - "Refer HTTP/1.1 for details"), -1); + "Refer HTTP/1.0 error code for details"), -1); } this->size_ = ACE_static_cast (off_t, len); @@ -109,6 +110,9 @@ ACEXML_HttpCharStream::open (const ACEXML_Char *url) int ACEXML_HttpCharStream::get_url (size_t& len) { + if (this->stream_ == 0) + return -1; + int header_state = HDST_LINE1_PROTOCOL; int status = 0; size_t b = 0; @@ -213,6 +217,8 @@ ACEXML_HttpCharStream::get_url (size_t& len) } } end_of_headers: + if (b == 0) + return -1; ++b; // Store the address of the beginning of data. We will use it to seek to // beginning of the data in the URL. @@ -236,6 +242,9 @@ ACEXML_HttpCharStream::get_url (size_t& len) if (this->stream_->seek (data_offset, SEEK_SET) == -1) ACE_ERROR_RETURN ((LM_ERROR, "%s: %m", "Error in seeking to beginning of data"), -1); + + if (this->determine_encoding() == -1) + return -1; return status; } @@ -257,7 +266,7 @@ ACEXML_HttpCharStream::send_request (void) // Ensure that the <command> memory is deallocated. ACE_Auto_Basic_Array_Ptr<char> cmd_ptr (command); - int bytes = ACE_OS::sprintf (command, "GET %s HTTP/1.1\r\n", path); + int bytes = ACE_OS::sprintf (command, "GET %s HTTP/1.0\r\n", path); bytes += ACE_OS::sprintf (&command[bytes], "Host: %s\r\n", this->url_addr_->get_host_name ()); bytes += ACE_OS::sprintf (&command[bytes], "\r\n"); @@ -275,6 +284,8 @@ ACEXML_HttpCharStream::send_request (void) int ACEXML_HttpCharStream::available (void) { + if (this->stream_ == 0) + return -1; return ACE_static_cast (int, this->stream_->available()); } @@ -302,16 +313,67 @@ ACEXML_HttpCharStream::close (void) } int -ACEXML_HttpCharStream::get (ACEXML_Char& ch) +ACEXML_HttpCharStream::determine_encoding (void) { - ch = (ACEXML_Char) this->stream_->get_char(); - return (ch == (ACEXML_Char)EOF ? -1 :0); + if (this->stream_ == 0) + return -1; + + char input[4] = {0, 0, 0, 0}; + int i = 0; + for (; i < 4 && input[i] != -1; ++i) + input[i] = this->stream_->peek_char(i); + if (i < 4) + return -1; + const ACEXML_Char* temp = ACEXML_Encoding::get_encoding (input); + if (!temp) + return -1; + else + { + this->encoding_ = ACE::strnew (temp); + // ACE_DEBUG ((LM_DEBUG, "URI's encoding is %s\n", this->encoding_)); + } + // Move over the byte-order-mark if present. + for (int j = 0; j < 3; ++j) + { + if (input[i] == '\xFF' || input[i] == '\xFE' || input[i] == '\xEF' || + input[i] == '\xBB' || input[i] == '\xBF') + { + this->stream_->get_char(); + continue; + } + break; + } + return 0; +} + +void +ACEXML_HttpCharStream::rewind (void) +{ + if (this->stream_ == 0) + return; + this->stream_->rewind(); +} + +const ACEXML_Char* +ACEXML_HttpCharStream::getEncoding (void) +{ + return this->encoding_; +} + +const ACEXML_Char* +ACEXML_HttpCharStream::getSystemId (void) +{ + return this->url_; } + int ACEXML_HttpCharStream::read (ACEXML_Char *str, size_t len) { + if (this->stream_ == 0) + return -1; + len = len * sizeof (ACEXML_Char); char* temp = ACE_const_cast (char*, this->stream_->recv (len)); str = ACE_TEXT_CHAR_TO_TCHAR (temp); if (str == 0) @@ -319,20 +381,79 @@ ACEXML_HttpCharStream::read (ACEXML_Char *str, return ACE_static_cast (int, len); } + +int +ACEXML_HttpCharStream::get (ACEXML_Char& ch) +{ + if (this->stream_ == 0) + return -1; +#if defined (ACE_USES_WCHAR) + return this->get_i (ch); +#else + ch = (ACEXML_Char) this->stream_->get_char(); + return (ch == (ACEXML_Char)EOF ? -1 :0); +#endif /* ACE_USES_WCHAR */ +} + int ACEXML_HttpCharStream::peek (void) { + if (this->stream_ == 0) + return -1; + +#if defined (ACE_USES_WCHAR) + return this->peek_i(); +#else return this->stream_->peek_char (0); +#endif /* ACE_USES_WCHAR */ } -void -ACEXML_HttpCharStream::rewind (void) + +#if defined (ACE_USES_WCHAR) +int +ACEXML_HttpCharStream::get_i (ACEXML_Char& ch) { - this->stream_->rewind(); + if (ACE_OS::strcmp (this->encoding_, ACE_TEXT ("UTF-8")) == 0) + { + ch = (ACEXML_Char) this->stream_->get_char(); + return (ch == (ACEXML_Char)EOF ? -1 : 0); + } + int BE = (ACE_OS::strcmp (this->encoding_, + ACE_TEXT ("UTF-16BE")) == 0) ? 1 : 0; + ACEXML_Char input[2] = {0}; + int i = 0; + for (; i < 2 && input[i] != EOF; ++i) + { + input[i] = this->stream_->get_char(); + } + if (i < 2) + { + ch = 0; + return input[i]; + } + ch = BE ? input[0] << 8 | input[1] : input[1] << 8 | input[0]; + return 0; } -const ACEXML_Char* -ACEXML_HttpCharStream::getEncoding (void) +int +ACEXML_HttpCharStream::peek_i (void) { - return this->encoding_; + // If we are reading a UTF-8 encoded file, just use the plain unget. + if (ACE_OS::strcmp (this->encoding_, ACE_TEXT ("UTF-8")) == 0) + { + ACEXML_Char ch = (ACEXML_Char) this->stream_->peek_char (0); + return ch; + } + + int BE = (ACE_OS::strcmp (this->encoding_, + ACE_TEXT ("UTF-16BE")) == 0) ? 1 : 0; + // Peek into the stream. + ACEXML_Char input[2]; + int i = 0; + for (; i < 2 && (input[i] = this->stream_->peek_char (i)) != EOF; ++i) + ; + if (i < 2) + return -1; + return (BE ? input[0] << 8 | input[1] : input[1] << 8 | input[0]); } +#endif /* ACE_USES_WCHAR */ diff --git a/ACEXML/common/HttpCharStream.h b/ACEXML/common/HttpCharStream.h index 7bce23a224b..75c98ecbaf7 100644 --- a/ACEXML/common/HttpCharStream.h +++ b/ACEXML/common/HttpCharStream.h @@ -62,8 +62,7 @@ public: /** * Read the next batch of ACEXML_Char strings */ - virtual int read (ACEXML_Char *str, - size_t len); + virtual int read (ACEXML_Char *str, size_t len); /** * Peek the next ACEXML_Char in the CharStream. Return the @@ -77,12 +76,39 @@ public: virtual void rewind (void); /** + * Determine the encoding of the file. + */ + virtual int determine_encoding (void); + + /** * Get the encoding of the file */ virtual const ACEXML_Char* getEncoding (void); + /* + * Get the systemId for the underlying CharStream + */ + virtual const ACEXML_Char* getSystemId (void); + + private: +#if defined (ACE_USES_WCHAR) + /** + * Read the next character from the stream taking into account the + * encoding of the file. + */ + int get_i (ACEXML_Char& ch); + + /** + * Read the next character from the stream taking into account the + * encoding of the file. Subsequent call to get() returns this + * character. + */ + int peek_i (void); + +#endif /* ACE_USES_WCHAR */ + /** * Send a HTTP/1.1 request to fetch the contents of the URL. */ diff --git a/ACEXML/common/InputSource.cpp b/ACEXML/common/InputSource.cpp index 0dcdeb0f2ba..8673420d732 100644 --- a/ACEXML/common/InputSource.cpp +++ b/ACEXML/common/InputSource.cpp @@ -1,70 +1,78 @@ // -*- C++ -*- $Id$ #include "ACEXML/common/InputSource.h" +#include "ACEXML/common/StreamFactory.h" #include "ace/ACE.h" +#include "ace/Swap.h" ACEXML_InputSource::ACEXML_InputSource (void) - : publicId_ (0), - systemId_ (0), - charStream_ (0), - encoding_ (0) + : charStream_ (0), + encoding_ (0), + publicId_ (0), + systemId_ (0) { } ACEXML_InputSource::ACEXML_InputSource (ACEXML_CharStream *stm) - : publicId_ (0), - systemId_ (0), - charStream_ (stm), - encoding_ (0) + : charStream_ (stm), + encoding_ (ACE::strnew (stm->getEncoding())), + publicId_ (0), + systemId_ (stm->getSystemId() ? ACE::strnew (stm->getSystemId()): 0) { - this->setEncoding (stm->getEncoding()); } /* * Create a new input source with a character stream. - * / - InputSource (Reader); + * */ ACEXML_InputSource::ACEXML_InputSource (const ACEXML_Char *systemId) - : systemId_ (ACE::strnew (systemId)) + : charStream_ (0), + encoding_ (0), + publicId_ (0), + systemId_ (ACE::strnew (systemId)) { + ACEXML_StreamFactory factory; + ACEXML_CharStream* stm = factory.create_stream (this->systemId_); + if (stm) + { + this->setCharStream (stm); + this->setEncoding (this->charStream_->getEncoding()); + } } ACEXML_InputSource::~ACEXML_InputSource (void) { delete[] this->publicId_; + this->publicId_ = 0; delete[] this->systemId_; + this->systemId_ = 0; delete this->charStream_; + this->charStream_ = 0; delete[] this->encoding_; + this->encoding_ = 0; } ACEXML_CharStream * -ACEXML_InputSource::getCharStream (void) +ACEXML_InputSource::getCharStream (void) const { return this->charStream_; } - /* - * Get the character stream for this input source. - * / - virtual Reader *getCharacterStream (void); - */ - const ACEXML_Char * -ACEXML_InputSource::getEncoding (void) +ACEXML_InputSource::getEncoding (void) const { return this->encoding_; } const ACEXML_Char * -ACEXML_InputSource::getPublicId (void) +ACEXML_InputSource::getPublicId (void) const { return this->publicId_; } const ACEXML_Char * -ACEXML_InputSource::getSystemId (void) +ACEXML_InputSource::getSystemId (void) const { return this->systemId_; } @@ -76,25 +84,23 @@ ACEXML_InputSource::setCharStream (ACEXML_CharStream *stm) this->charStream_ = stm; } - /* - * Set the character stream for this input source. - * - */ - void ACEXML_InputSource::setEncoding (const ACEXML_Char *encoding) { + delete[] this->encoding_; this->encoding_ = ACE::strnew (encoding); } void ACEXML_InputSource::setPublicId (const ACEXML_Char *publicId) { + delete[] this->publicId_; this->publicId_ = ACE::strnew (publicId); } void ACEXML_InputSource::setSystemId (const ACEXML_Char *systemId) { + delete[] this->systemId_; this->systemId_ = ACE::strnew (systemId); } diff --git a/ACEXML/common/InputSource.h b/ACEXML/common/InputSource.h index 2d8c5a7beb5..78f54069df2 100644 --- a/ACEXML/common/InputSource.h +++ b/ACEXML/common/InputSource.h @@ -53,75 +53,76 @@ class ACEXML_Export ACEXML_InputSource { public: - /* + /** * Default constructor. */ ACEXML_InputSource (void); - /* + + /** * Create a new input source with a ACEXML_Char stream. * Notice that ACEXML_InputSource assumes the ownership * of <stream> */ - ACEXML_InputSource (ACEXML_CharStream *stream); + ACE_EXPLICIT ACEXML_InputSource (ACEXML_CharStream *stream); - /* + /** * Create a new input source with a system identifier. */ ACEXML_InputSource (const ACEXML_Char *systemId); - /* + /** * Default destructor. */ virtual ~ACEXML_InputSource (void); - /* + /** * Get the ACEXML_Char stream for this input source. */ - virtual ACEXML_CharStream *getCharStream (void); + virtual ACEXML_CharStream *getCharStream (void) const; - /* + /** * Get the character encoding for a byte stream or URI. */ - virtual const ACEXML_Char *getEncoding (void); + virtual const ACEXML_Char *getEncoding (void) const; - /* + /** * Get the public identifier for this input source. */ - virtual const ACEXML_Char *getPublicId (void); + virtual const ACEXML_Char *getPublicId (void) const; - /* + /** * Get the system identifier for this input source. */ - virtual const ACEXML_Char *getSystemId (void); + virtual const ACEXML_Char *getSystemId (void) const; - /* + /** * Set the ACEXML_Char stream for this input source. * Notice that ACEXML_InputSource assumes the ownership * of <stream> */ virtual void setCharStream (ACEXML_CharStream *charStream); - /* + /** * Set the character encoding, if known. */ virtual void setEncoding (const ACEXML_Char *encoding); - /* + /** * Set the public identifier for this input source. */ virtual void setPublicId (const ACEXML_Char *publicId); - /* + /** * Set the public identifier for this input source. */ virtual void setSystemId (const ACEXML_Char *systemId); private: - ACEXML_Char *publicId_; - ACEXML_Char *systemId_; ACEXML_CharStream *charStream_; ACEXML_Char *encoding_; + ACEXML_Char *publicId_; + ACEXML_Char *systemId_; }; diff --git a/ACEXML/common/LocatorImpl.cpp b/ACEXML/common/LocatorImpl.cpp index 0ccf9c1773a..7b98f9178e1 100644 --- a/ACEXML/common/LocatorImpl.cpp +++ b/ACEXML/common/LocatorImpl.cpp @@ -14,9 +14,19 @@ ACEXML_LocatorImpl::ACEXML_LocatorImpl (void) { } +ACEXML_LocatorImpl::ACEXML_LocatorImpl (const ACEXML_Char* systemId, + const ACEXML_Char* publicId) + : publicId_ (publicId ? ACE::strnew (publicId) : 0), + systemId_ (systemId ? ACE::strnew (systemId) : 0), + lineNumber_ (1), + columnNumber_ (0) +{ +} + + ACEXML_LocatorImpl::ACEXML_LocatorImpl (const ACEXML_Locator& locator) - : publicId_ (ACE::strnew (locator.getPublicId ())), - systemId_ (ACE::strnew (locator.getSystemId ())), + : publicId_ (locator.getPublicId() ? ACE::strnew(locator.getPublicId ()): 0), + systemId_ (locator.getSystemId() ? ACE::strnew(locator.getSystemId ()): 0), lineNumber_ (locator.getLineNumber ()), columnNumber_ (locator.getColumnNumber ()) { @@ -24,7 +34,7 @@ ACEXML_LocatorImpl::ACEXML_LocatorImpl (const ACEXML_Locator& locator) ACEXML_LocatorImpl::~ACEXML_LocatorImpl (void) { - + this->reset(); } void diff --git a/ACEXML/common/LocatorImpl.h b/ACEXML/common/LocatorImpl.h index 5e0bbdace23..2bea4e80c22 100644 --- a/ACEXML/common/LocatorImpl.h +++ b/ACEXML/common/LocatorImpl.h @@ -66,7 +66,13 @@ public: */ ACEXML_LocatorImpl (void); - /* + /** + * Construct a locator with systemId and publicId + * + */ + ACEXML_LocatorImpl (const ACEXML_Char* systemId, + const ACEXML_Char* publicId); + /** * Copy constructor. Create a persistent copy of the current state * of a locator. When the original locator changes, this copy will * still keep the original values (and it can be used outside the diff --git a/ACEXML/common/Makefile b/ACEXML/common/Makefile index 2a0eb4077b8..b817a5c4859 100644 --- a/ACEXML/common/Makefile +++ b/ACEXML/common/Makefile @@ -1,2721 +1,14 @@ +# $Id$ #---------------------------------------------------------------------------- -# $Id$ -# -# Makefile for the server-side ACE network services +# GNU ACE Workspace #---------------------------------------------------------------------------- -LIB = libACEXML.a -SHLIB = libACEXML.$(SOEXT) +include $(ACE_ROOT)/include/makeinclude/macros.GNU +TARGETS_NESTED := $(TARGETS_NESTED:.nested=) -FILES = Attributes_Def_Builder \ - AttributesImpl \ - CharStream \ - DefaultHandler \ - DTD_Manager \ - Element_Def_Builder \ - Env \ - Exception \ - FileCharStream \ - InputSource \ - LocatorImpl \ - NamespaceSupport \ - SAXExceptions \ - StrCharStream \ - Transcode \ - Validator \ - XMLFilterImpl \ - XML_Codecs \ - Mem_Map_Stream \ - URL_Addr \ - HttpCharStream \ - StreamFactory \ - Encoding - -DEFS = $(addsuffix .h,$(FILES)) -LSRC = $(addsuffix .cpp,$(FILES)) - -LIBS += $(ACELIB) - -BUILD = $(VLIB) $(VSHLIB) - -#---------------------------------------------------------------------------- -# Include macros and targets -#---------------------------------------------------------------------------- - -include $(ACE_ROOT)/include/makeinclude/wrapper_macros.GNU -include $(ACE_ROOT)/include/makeinclude/macros.GNU -include $(ACE_ROOT)/include/makeinclude/rules.common.GNU -include $(ACE_ROOT)/include/makeinclude/rules.nonested.GNU -include $(ACE_ROOT)/include/makeinclude/rules.lib.GNU -include $(ACE_ROOT)/include/makeinclude/rules.local.GNU - -#---------------------------------------------------------------------------- -# Local targets -#---------------------------------------------------------------------------- - -ifeq ($(shared_libs),1) -ifneq ($(SHLIB),) -CPPFLAGS += -DACEXML_BUILD_DLL -endif +$(TARGETS_NESTED): +ifneq (Windows,$(findstring Windows,$(OS))) + @$(MAKE) -f Makefile.ACEXML -C . $(@); +else + -@cmd /c "$(MAKE) -f Makefile.ACEXML -C . $(@)" endif - -#---------------------------------------------------------------------------- -# Dependencies -#---------------------------------------------------------------------------- -# DO NOT DELETE THIS LINE -- g++dep uses it. -# DO NOT PUT ANYTHING AFTER THIS LINE, IT WILL GO AWAY. - - -.obj/Attributes_Def_Builder.o .obj/Attributes_Def_Builder.so .shobj/Attributes_Def_Builder.o .shobj/Attributes_Def_Builder.so: Attributes_Def_Builder.cpp \ - Attributes_Def_Builder.h \ - $(ACE_ROOT)/ace/pre.h \ - ACEXML_Export.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - XML_Types.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h \ - $(ACE_ROOT)/ace/Trace.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - $(ACE_ROOT)/ace/SString.i \ - Env.h \ - XML_Macros.h \ - $(ACE_ROOT)/ace/Exception_Macros.h \ - Exception.h \ - Exception.i \ - Env.i \ - SAXExceptions.h \ - SAXExceptions.i - -.obj/AttributesImpl.o .obj/AttributesImpl.so .shobj/AttributesImpl.o .shobj/AttributesImpl.so: AttributesImpl.cpp \ - AttributesImpl.h \ - $(ACE_ROOT)/ace/pre.h \ - ACEXML_Export.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - Attributes.h \ - XML_Types.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h \ - $(ACE_ROOT)/ace/Trace.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - $(ACE_ROOT)/ace/SString.i \ - $(ACE_ROOT)/ace/Containers_T.h \ - $(ACE_ROOT)/ace/Containers.h \ - $(ACE_ROOT)/ace/Containers.i \ - $(ACE_ROOT)/ace/Array_Base.h \ - $(ACE_ROOT)/ace/Array_Base.inl \ - $(ACE_ROOT)/ace/Array_Base.cpp \ - $(ACE_ROOT)/ace/Unbounded_Queue.h \ - $(ACE_ROOT)/ace/Unbounded_Queue.inl \ - $(ACE_ROOT)/ace/Unbounded_Queue.cpp \ - $(ACE_ROOT)/ace/Containers_T.i \ - $(ACE_ROOT)/ace/Containers_T.cpp \ - AttributesImpl.i - -.obj/CharStream.o .obj/CharStream.so .shobj/CharStream.o .shobj/CharStream.so: CharStream.cpp \ - CharStream.h \ - $(ACE_ROOT)/ace/pre.h \ - ACEXML_Export.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - XML_Types.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h \ - $(ACE_ROOT)/ace/Trace.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - $(ACE_ROOT)/ace/SString.i - -.obj/DefaultHandler.o .obj/DefaultHandler.so .shobj/DefaultHandler.o .shobj/DefaultHandler.so: DefaultHandler.cpp \ - DefaultHandler.h \ - $(ACE_ROOT)/ace/pre.h \ - ACEXML_Export.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - ContentHandler.h \ - Env.h \ - XML_Macros.h \ - $(ACE_ROOT)/ace/Exception_Macros.h \ - Exception.h \ - XML_Types.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h \ - $(ACE_ROOT)/ace/Trace.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - $(ACE_ROOT)/ace/SString.i \ - Exception.i \ - Env.i \ - SAXExceptions.h \ - SAXExceptions.i \ - Locator.h \ - Attributes.h \ - DTDHandler.h \ - EntityResolver.h \ - InputSource.h \ - CharStream.h \ - ErrorHandler.h \ - DefaultHandler.i - -.obj/DTD_Manager.o .obj/DTD_Manager.so .shobj/DTD_Manager.o .shobj/DTD_Manager.so: DTD_Manager.cpp \ - DTD_Manager.h \ - $(ACE_ROOT)/ace/pre.h \ - ACEXML_Export.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - Attributes_Def_Builder.h \ - XML_Types.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h \ - $(ACE_ROOT)/ace/Trace.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - $(ACE_ROOT)/ace/SString.i \ - Env.h \ - XML_Macros.h \ - $(ACE_ROOT)/ace/Exception_Macros.h \ - Exception.h \ - Exception.i \ - Env.i \ - SAXExceptions.h \ - SAXExceptions.i \ - Element_Def_Builder.h \ - Validator.h \ - Attributes.h - -.obj/Element_Def_Builder.o .obj/Element_Def_Builder.so .shobj/Element_Def_Builder.o .shobj/Element_Def_Builder.so: Element_Def_Builder.cpp \ - Element_Def_Builder.h \ - $(ACE_ROOT)/ace/pre.h \ - ACEXML_Export.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Trace.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - XML_Types.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/SString.i \ - Env.h \ - XML_Macros.h \ - $(ACE_ROOT)/ace/Exception_Macros.h \ - Exception.h \ - Exception.i \ - Env.i \ - SAXExceptions.h \ - SAXExceptions.i - -.obj/Env.o .obj/Env.so .shobj/Env.o .shobj/Env.so: Env.cpp Env.h \ - $(ACE_ROOT)/ace/pre.h \ - ACEXML_Export.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - XML_Macros.h \ - $(ACE_ROOT)/ace/Exception_Macros.h \ - Exception.h \ - XML_Types.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h \ - $(ACE_ROOT)/ace/Trace.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - $(ACE_ROOT)/ace/SString.i \ - Exception.i \ - Env.i - -.obj/Exception.o .obj/Exception.so .shobj/Exception.o .shobj/Exception.so: Exception.cpp \ - Exception.h \ - $(ACE_ROOT)/ace/pre.h \ - ACEXML_Export.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - XML_Types.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h \ - $(ACE_ROOT)/ace/Trace.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - $(ACE_ROOT)/ace/SString.i \ - XML_Macros.h \ - $(ACE_ROOT)/ace/Exception_Macros.h \ - Exception.i - -.obj/FileCharStream.o .obj/FileCharStream.so .shobj/FileCharStream.o .shobj/FileCharStream.so: FileCharStream.cpp \ - FileCharStream.h \ - $(ACE_ROOT)/ace/pre.h \ - ACEXML_Export.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - CharStream.h \ - XML_Types.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h \ - $(ACE_ROOT)/ace/Trace.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - $(ACE_ROOT)/ace/SString.i \ - Encoding.h - -.obj/InputSource.o .obj/InputSource.so .shobj/InputSource.o .shobj/InputSource.so: InputSource.cpp \ - InputSource.h \ - $(ACE_ROOT)/ace/pre.h \ - ACEXML_Export.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - CharStream.h \ - XML_Types.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h \ - $(ACE_ROOT)/ace/Trace.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - $(ACE_ROOT)/ace/SString.i - -.obj/LocatorImpl.o .obj/LocatorImpl.so .shobj/LocatorImpl.o .shobj/LocatorImpl.so: LocatorImpl.cpp \ - LocatorImpl.h \ - $(ACE_ROOT)/ace/pre.h \ - ACEXML_Export.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - Locator.h \ - XML_Types.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h \ - $(ACE_ROOT)/ace/Trace.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - $(ACE_ROOT)/ace/SString.i \ - LocatorImpl.i - -.obj/NamespaceSupport.o .obj/NamespaceSupport.so .shobj/NamespaceSupport.o .shobj/NamespaceSupport.so: NamespaceSupport.cpp \ - NamespaceSupport.h \ - $(ACE_ROOT)/ace/pre.h \ - ACEXML_Export.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - XML_Types.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h \ - $(ACE_ROOT)/ace/Trace.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - $(ACE_ROOT)/ace/SString.i \ - $(ACE_ROOT)/ace/Functor.h \ - $(ACE_ROOT)/ace/Functor.i \ - $(ACE_ROOT)/ace/Functor_T.h \ - $(ACE_ROOT)/ace/Functor_T.i \ - $(ACE_ROOT)/ace/Functor_T.cpp \ - $(ACE_ROOT)/ace/Hash_Map_Manager.h \ - $(ACE_ROOT)/ace/Hash_Map_Manager_T.h \ - $(ACE_ROOT)/ace/Hash_Map_Manager_T.i \ - $(ACE_ROOT)/ace/Hash_Map_Manager_T.cpp \ - $(ACE_ROOT)/ace/Service_Config.h \ - $(ACE_ROOT)/ace/Unbounded_Queue.h \ - $(ACE_ROOT)/ace/Unbounded_Queue.inl \ - $(ACE_ROOT)/ace/Unbounded_Queue.cpp \ - $(ACE_ROOT)/ace/XML_Svc_Conf.h \ - $(ACE_ROOT)/ace/Service_Config.i \ - $(ACE_ROOT)/ace/Reactor.h \ - $(ACE_ROOT)/ace/Handle_Set.h \ - $(ACE_ROOT)/ace/Handle_Set.i \ - $(ACE_ROOT)/ace/Timer_Queue.h \ - $(ACE_ROOT)/ace/Timer_Queue_T.h \ - $(ACE_ROOT)/ace/Test_and_Set.h \ - $(ACE_ROOT)/ace/Test_and_Set.i \ - $(ACE_ROOT)/ace/Test_and_Set.cpp \ - $(ACE_ROOT)/ace/Timer_Queue_T.i \ - $(ACE_ROOT)/ace/Timer_Queue_T.cpp \ - $(ACE_ROOT)/ace/Reactor.i \ - $(ACE_ROOT)/ace/Reactor_Impl.h \ - $(ACE_ROOT)/ace/Svc_Conf_Tokens.h \ - $(ACE_ROOT)/ace/Containers_T.h \ - $(ACE_ROOT)/ace/Containers.h \ - $(ACE_ROOT)/ace/Containers.i \ - $(ACE_ROOT)/ace/Array_Base.h \ - $(ACE_ROOT)/ace/Array_Base.inl \ - $(ACE_ROOT)/ace/Array_Base.cpp \ - $(ACE_ROOT)/ace/Containers_T.i \ - $(ACE_ROOT)/ace/Containers_T.cpp \ - NamespaceSupport.i - -.obj/SAXExceptions.o .obj/SAXExceptions.so .shobj/SAXExceptions.o .shobj/SAXExceptions.so: SAXExceptions.cpp \ - SAXExceptions.h \ - $(ACE_ROOT)/ace/pre.h \ - ACEXML_Export.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - Exception.h \ - XML_Types.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h \ - $(ACE_ROOT)/ace/Trace.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - $(ACE_ROOT)/ace/SString.i \ - XML_Macros.h \ - $(ACE_ROOT)/ace/Exception_Macros.h \ - Exception.i \ - SAXExceptions.i - -.obj/StrCharStream.o .obj/StrCharStream.so .shobj/StrCharStream.o .shobj/StrCharStream.so: StrCharStream.cpp \ - StrCharStream.h \ - $(ACE_ROOT)/ace/pre.h \ - ACEXML_Export.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - CharStream.h \ - XML_Types.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h \ - $(ACE_ROOT)/ace/Trace.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - $(ACE_ROOT)/ace/SString.i \ - Encoding.h - -.obj/Transcode.o .obj/Transcode.so .shobj/Transcode.o .shobj/Transcode.so: Transcode.cpp \ - Transcode.h \ - $(ACE_ROOT)/ace/pre.h \ - ACEXML_Export.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - XML_Types.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h \ - $(ACE_ROOT)/ace/Trace.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - $(ACE_ROOT)/ace/SString.i \ - Transcode.i - -.obj/Validator.o .obj/Validator.so .shobj/Validator.o .shobj/Validator.so: Validator.cpp \ - Validator.h \ - $(ACE_ROOT)/ace/pre.h \ - ACEXML_Export.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - Attributes.h \ - XML_Types.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h \ - $(ACE_ROOT)/ace/Trace.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - $(ACE_ROOT)/ace/SString.i \ - Env.h \ - XML_Macros.h \ - $(ACE_ROOT)/ace/Exception_Macros.h \ - Exception.h \ - Exception.i \ - Env.i \ - SAXExceptions.h \ - SAXExceptions.i - -.obj/XMLFilterImpl.o .obj/XMLFilterImpl.so .shobj/XMLFilterImpl.o .shobj/XMLFilterImpl.so: XMLFilterImpl.cpp \ - XMLFilterImpl.h \ - $(ACE_ROOT)/ace/pre.h \ - XMLFilter.h \ - ACEXML_Export.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - XMLReader.h \ - ContentHandler.h \ - Env.h \ - XML_Macros.h \ - $(ACE_ROOT)/ace/Exception_Macros.h \ - Exception.h \ - XML_Types.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h \ - $(ACE_ROOT)/ace/Trace.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - $(ACE_ROOT)/ace/SString.i \ - Exception.i \ - Env.i \ - SAXExceptions.h \ - SAXExceptions.i \ - Locator.h \ - Attributes.h \ - DTDHandler.h \ - EntityResolver.h \ - InputSource.h \ - CharStream.h \ - ErrorHandler.h \ - XMLFilterImpl.i - -.obj/XML_Codecs.o .obj/XML_Codecs.so .shobj/XML_Codecs.o .shobj/XML_Codecs.so: XML_Codecs.cpp $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/pre.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - $(ACE_ROOT)/ace/Trace.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - XML_Codecs.h \ - ACEXML_Export.h \ - XML_Types.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/SString.i \ - $(ACE_ROOT)/ace/Codecs.h - -.obj/Mem_Map_Stream.o .obj/Mem_Map_Stream.so .shobj/Mem_Map_Stream.o .shobj/Mem_Map_Stream.so: Mem_Map_Stream.cpp \ - $(ACE_ROOT)/ace/FILE_Addr.h \ - $(ACE_ROOT)/ace/pre.h $(ACE_ROOT)/ace/Addr.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - $(ACE_ROOT)/ace/Addr.i \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h \ - $(ACE_ROOT)/ace/Trace.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/FILE_Addr.i \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - $(ACE_ROOT)/ace/SString.i \ - Mem_Map_Stream.h \ - ACEXML_Export.h \ - $(ACE_ROOT)/ace/SOCK_Stream.h \ - $(ACE_ROOT)/ace/SOCK_IO.h \ - $(ACE_ROOT)/ace/SOCK.h \ - $(ACE_ROOT)/ace/IPC_SAP.h \ - $(ACE_ROOT)/ace/IPC_SAP.i \ - $(ACE_ROOT)/ace/SOCK.i \ - $(ACE_ROOT)/ace/SOCK_IO.i \ - $(ACE_ROOT)/ace/INET_Addr.h \ - $(ACE_ROOT)/ace/INET_Addr.i \ - $(ACE_ROOT)/ace/SOCK_Stream.i \ - $(ACE_ROOT)/ace/SOCK_Connector.h \ - $(ACE_ROOT)/ace/SOCK_Connector.i \ - $(ACE_ROOT)/ace/Connector.h \ - $(ACE_ROOT)/ace/Service_Object.h \ - $(ACE_ROOT)/ace/Shared_Object.h \ - $(ACE_ROOT)/ace/Shared_Object.i \ - $(ACE_ROOT)/ace/Svc_Conf_Tokens.h \ - $(ACE_ROOT)/ace/DLL.h \ - $(ACE_ROOT)/ace/Service_Object.i \ - $(ACE_ROOT)/ace/Map_Manager.h \ - $(ACE_ROOT)/ace/Map_Manager.i \ - $(ACE_ROOT)/ace/Map_Manager.cpp \ - $(ACE_ROOT)/ace/Service_Config.h \ - $(ACE_ROOT)/ace/Unbounded_Queue.h \ - $(ACE_ROOT)/ace/Unbounded_Queue.inl \ - $(ACE_ROOT)/ace/Unbounded_Queue.cpp \ - $(ACE_ROOT)/ace/XML_Svc_Conf.h \ - $(ACE_ROOT)/ace/Service_Config.i \ - $(ACE_ROOT)/ace/Reactor.h \ - $(ACE_ROOT)/ace/Handle_Set.h \ - $(ACE_ROOT)/ace/Handle_Set.i \ - $(ACE_ROOT)/ace/Timer_Queue.h \ - $(ACE_ROOT)/ace/Timer_Queue_T.h \ - $(ACE_ROOT)/ace/Test_and_Set.h \ - $(ACE_ROOT)/ace/Test_and_Set.i \ - $(ACE_ROOT)/ace/Test_and_Set.cpp \ - $(ACE_ROOT)/ace/Timer_Queue_T.i \ - $(ACE_ROOT)/ace/Timer_Queue_T.cpp \ - $(ACE_ROOT)/ace/Reactor.i \ - $(ACE_ROOT)/ace/Reactor_Impl.h \ - $(ACE_ROOT)/ace/Strategies_T.h \ - $(ACE_ROOT)/ace/Hash_Map_Manager_T.h \ - $(ACE_ROOT)/ace/Functor.h \ - $(ACE_ROOT)/ace/Functor.i \ - $(ACE_ROOT)/ace/Functor_T.h \ - $(ACE_ROOT)/ace/Functor_T.i \ - $(ACE_ROOT)/ace/Functor_T.cpp \ - $(ACE_ROOT)/ace/Hash_Map_Manager_T.i \ - $(ACE_ROOT)/ace/Hash_Map_Manager_T.cpp \ - $(ACE_ROOT)/ace/Thread_Manager.h \ - $(ACE_ROOT)/ace/Thread_Exit.h \ - $(ACE_ROOT)/ace/Thread_Control.h \ - $(ACE_ROOT)/ace/Thread_Control.inl \ - $(ACE_ROOT)/ace/Containers.h \ - $(ACE_ROOT)/ace/Containers.i \ - $(ACE_ROOT)/ace/Containers_T.h \ - $(ACE_ROOT)/ace/Array_Base.h \ - $(ACE_ROOT)/ace/Array_Base.inl \ - $(ACE_ROOT)/ace/Array_Base.cpp \ - $(ACE_ROOT)/ace/Containers_T.i \ - $(ACE_ROOT)/ace/Containers_T.cpp \ - $(ACE_ROOT)/ace/Singleton.h \ - $(ACE_ROOT)/ace/Singleton.i \ - $(ACE_ROOT)/ace/Singleton.cpp \ - $(ACE_ROOT)/ace/Object_Manager.h \ - $(ACE_ROOT)/ace/Object_Manager.i \ - $(ACE_ROOT)/ace/Managed_Object.h \ - $(ACE_ROOT)/ace/Managed_Object.i \ - $(ACE_ROOT)/ace/Managed_Object.cpp \ - $(ACE_ROOT)/ace/Framework_Component.h \ - $(ACE_ROOT)/ace/Framework_Component.inl \ - $(ACE_ROOT)/ace/Framework_Component_T.h \ - $(ACE_ROOT)/ace/Framework_Component_T.inl \ - $(ACE_ROOT)/ace/Framework_Component_T.cpp \ - $(ACE_ROOT)/ace/Thread_Manager.i \ - $(ACE_ROOT)/ace/Connection_Recycling_Strategy.h \ - $(ACE_ROOT)/ace/Recyclable.h \ - $(ACE_ROOT)/ace/Recyclable.inl \ - $(ACE_ROOT)/ace/Refcountable.h \ - $(ACE_ROOT)/ace/Refcountable.inl \ - $(ACE_ROOT)/ace/Hashable.h \ - $(ACE_ROOT)/ace/Hashable.inl \ - $(ACE_ROOT)/ace/Strategies_T.i \ - $(ACE_ROOT)/ace/Strategies_T.cpp \ - $(ACE_ROOT)/ace/Service_Repository.h \ - $(ACE_ROOT)/ace/Service_Repository.i \ - $(ACE_ROOT)/ace/Service_Types.h \ - $(ACE_ROOT)/ace/Service_Types.i \ - $(ACE_ROOT)/ace/WFMO_Reactor.h \ - $(ACE_ROOT)/ace/Synch_Options.h \ - $(ACE_ROOT)/ace/Synch_Options.i \ - $(ACE_ROOT)/ace/Connector.cpp \ - $(ACE_ROOT)/ace/Svc_Handler.h \ - $(ACE_ROOT)/ace/Task.h $(ACE_ROOT)/ace/Task.i \ - $(ACE_ROOT)/ace/Task_T.h \ - $(ACE_ROOT)/ace/Message_Queue.h \ - $(ACE_ROOT)/ace/Message_Block.h \ - $(ACE_ROOT)/ace/Message_Block.i \ - $(ACE_ROOT)/ace/Message_Block_T.h \ - $(ACE_ROOT)/ace/Message_Block_T.i \ - $(ACE_ROOT)/ace/Message_Block_T.cpp \ - $(ACE_ROOT)/ace/IO_Cntl_Msg.h \ - $(ACE_ROOT)/ace/Message_Queue_T.h \ - $(ACE_ROOT)/ace/Message_Queue_T.i \ - $(ACE_ROOT)/ace/Message_Queue_T.cpp \ - $(ACE_ROOT)/ace/Notification_Strategy.h \ - $(ACE_ROOT)/ace/Notification_Strategy.inl \ - $(ACE_ROOT)/ace/Message_Queue.i \ - $(ACE_ROOT)/ace/Task_T.i \ - $(ACE_ROOT)/ace/Task_T.cpp \ - $(ACE_ROOT)/ace/Module.h \ - $(ACE_ROOT)/ace/Module.i \ - $(ACE_ROOT)/ace/Module.cpp \ - $(ACE_ROOT)/ace/Stream_Modules.h \ - $(ACE_ROOT)/ace/Stream_Modules.cpp \ - $(ACE_ROOT)/ace/Svc_Handler.cpp \ - $(ACE_ROOT)/ace/Dynamic.h \ - $(ACE_ROOT)/ace/Dynamic.i \ - XML_Types.h - -.obj/URL_Addr.o .obj/URL_Addr.so .shobj/URL_Addr.o .shobj/URL_Addr.so: URL_Addr.cpp $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/pre.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h \ - $(ACE_ROOT)/ace/Trace.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - URL_Addr.h \ - ACEXML_Export.h \ - $(ACE_ROOT)/ace/INET_Addr.h \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/Addr.h $(ACE_ROOT)/ace/Addr.i \ - $(ACE_ROOT)/ace/INET_Addr.i \ - XML_Types.h \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/SString.i \ - URL_Addr.inl - -.obj/HttpCharStream.o .obj/HttpCharStream.so .shobj/HttpCharStream.o .shobj/HttpCharStream.so: HttpCharStream.cpp $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/pre.h $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h \ - $(ACE_ROOT)/ace/Trace.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - HttpCharStream.h \ - ACEXML_Export.h \ - CharStream.h \ - XML_Types.h \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/SString.i \ - URL_Addr.h \ - $(ACE_ROOT)/ace/INET_Addr.h \ - $(ACE_ROOT)/ace/Addr.h $(ACE_ROOT)/ace/Addr.i \ - $(ACE_ROOT)/ace/INET_Addr.i \ - URL_Addr.inl \ - Mem_Map_Stream.h \ - $(ACE_ROOT)/ace/SOCK_Stream.h \ - $(ACE_ROOT)/ace/SOCK_IO.h \ - $(ACE_ROOT)/ace/SOCK.h \ - $(ACE_ROOT)/ace/IPC_SAP.h \ - $(ACE_ROOT)/ace/IPC_SAP.i \ - $(ACE_ROOT)/ace/SOCK.i \ - $(ACE_ROOT)/ace/SOCK_IO.i \ - $(ACE_ROOT)/ace/SOCK_Stream.i \ - $(ACE_ROOT)/ace/SOCK_Connector.h \ - $(ACE_ROOT)/ace/SOCK_Connector.i \ - $(ACE_ROOT)/ace/Connector.h \ - $(ACE_ROOT)/ace/Service_Object.h \ - $(ACE_ROOT)/ace/Shared_Object.h \ - $(ACE_ROOT)/ace/Shared_Object.i \ - $(ACE_ROOT)/ace/Svc_Conf_Tokens.h \ - $(ACE_ROOT)/ace/DLL.h \ - $(ACE_ROOT)/ace/Service_Object.i \ - $(ACE_ROOT)/ace/Map_Manager.h \ - $(ACE_ROOT)/ace/Map_Manager.i \ - $(ACE_ROOT)/ace/Map_Manager.cpp \ - $(ACE_ROOT)/ace/Service_Config.h \ - $(ACE_ROOT)/ace/Unbounded_Queue.h \ - $(ACE_ROOT)/ace/Unbounded_Queue.inl \ - $(ACE_ROOT)/ace/Unbounded_Queue.cpp \ - $(ACE_ROOT)/ace/XML_Svc_Conf.h \ - $(ACE_ROOT)/ace/Service_Config.i \ - $(ACE_ROOT)/ace/Reactor.h \ - $(ACE_ROOT)/ace/Handle_Set.h \ - $(ACE_ROOT)/ace/Handle_Set.i \ - $(ACE_ROOT)/ace/Timer_Queue.h \ - $(ACE_ROOT)/ace/Timer_Queue_T.h \ - $(ACE_ROOT)/ace/Test_and_Set.h \ - $(ACE_ROOT)/ace/Test_and_Set.i \ - $(ACE_ROOT)/ace/Test_and_Set.cpp \ - $(ACE_ROOT)/ace/Timer_Queue_T.i \ - $(ACE_ROOT)/ace/Timer_Queue_T.cpp \ - $(ACE_ROOT)/ace/Reactor.i \ - $(ACE_ROOT)/ace/Reactor_Impl.h \ - $(ACE_ROOT)/ace/Strategies_T.h \ - $(ACE_ROOT)/ace/Hash_Map_Manager_T.h \ - $(ACE_ROOT)/ace/Functor.h \ - $(ACE_ROOT)/ace/Functor.i \ - $(ACE_ROOT)/ace/Functor_T.h \ - $(ACE_ROOT)/ace/Functor_T.i \ - $(ACE_ROOT)/ace/Functor_T.cpp \ - $(ACE_ROOT)/ace/Hash_Map_Manager_T.i \ - $(ACE_ROOT)/ace/Hash_Map_Manager_T.cpp \ - $(ACE_ROOT)/ace/Thread_Manager.h \ - $(ACE_ROOT)/ace/Thread_Exit.h \ - $(ACE_ROOT)/ace/Thread_Control.h \ - $(ACE_ROOT)/ace/Thread_Control.inl \ - $(ACE_ROOT)/ace/Containers.h \ - $(ACE_ROOT)/ace/Containers.i \ - $(ACE_ROOT)/ace/Containers_T.h \ - $(ACE_ROOT)/ace/Array_Base.h \ - $(ACE_ROOT)/ace/Array_Base.inl \ - $(ACE_ROOT)/ace/Array_Base.cpp \ - $(ACE_ROOT)/ace/Containers_T.i \ - $(ACE_ROOT)/ace/Containers_T.cpp \ - $(ACE_ROOT)/ace/Singleton.h \ - $(ACE_ROOT)/ace/Singleton.i \ - $(ACE_ROOT)/ace/Singleton.cpp \ - $(ACE_ROOT)/ace/Object_Manager.h \ - $(ACE_ROOT)/ace/Object_Manager.i \ - $(ACE_ROOT)/ace/Managed_Object.h \ - $(ACE_ROOT)/ace/Managed_Object.i \ - $(ACE_ROOT)/ace/Managed_Object.cpp \ - $(ACE_ROOT)/ace/Framework_Component.h \ - $(ACE_ROOT)/ace/Framework_Component.inl \ - $(ACE_ROOT)/ace/Framework_Component_T.h \ - $(ACE_ROOT)/ace/Framework_Component_T.inl \ - $(ACE_ROOT)/ace/Framework_Component_T.cpp \ - $(ACE_ROOT)/ace/Thread_Manager.i \ - $(ACE_ROOT)/ace/Connection_Recycling_Strategy.h \ - $(ACE_ROOT)/ace/Recyclable.h \ - $(ACE_ROOT)/ace/Recyclable.inl \ - $(ACE_ROOT)/ace/Refcountable.h \ - $(ACE_ROOT)/ace/Refcountable.inl \ - $(ACE_ROOT)/ace/Hashable.h \ - $(ACE_ROOT)/ace/Hashable.inl \ - $(ACE_ROOT)/ace/Strategies_T.i \ - $(ACE_ROOT)/ace/Strategies_T.cpp \ - $(ACE_ROOT)/ace/Service_Repository.h \ - $(ACE_ROOT)/ace/Service_Repository.i \ - $(ACE_ROOT)/ace/Service_Types.h \ - $(ACE_ROOT)/ace/Service_Types.i \ - $(ACE_ROOT)/ace/WFMO_Reactor.h \ - $(ACE_ROOT)/ace/Synch_Options.h \ - $(ACE_ROOT)/ace/Synch_Options.i \ - $(ACE_ROOT)/ace/Connector.cpp \ - $(ACE_ROOT)/ace/Svc_Handler.h \ - $(ACE_ROOT)/ace/Task.h $(ACE_ROOT)/ace/Task.i \ - $(ACE_ROOT)/ace/Task_T.h \ - $(ACE_ROOT)/ace/Message_Queue.h \ - $(ACE_ROOT)/ace/Message_Block.h \ - $(ACE_ROOT)/ace/Message_Block.i \ - $(ACE_ROOT)/ace/Message_Block_T.h \ - $(ACE_ROOT)/ace/Message_Block_T.i \ - $(ACE_ROOT)/ace/Message_Block_T.cpp \ - $(ACE_ROOT)/ace/IO_Cntl_Msg.h \ - $(ACE_ROOT)/ace/Message_Queue_T.h \ - $(ACE_ROOT)/ace/Message_Queue_T.i \ - $(ACE_ROOT)/ace/Message_Queue_T.cpp \ - $(ACE_ROOT)/ace/Notification_Strategy.h \ - $(ACE_ROOT)/ace/Notification_Strategy.inl \ - $(ACE_ROOT)/ace/Message_Queue.i \ - $(ACE_ROOT)/ace/Task_T.i \ - $(ACE_ROOT)/ace/Task_T.cpp \ - $(ACE_ROOT)/ace/Module.h \ - $(ACE_ROOT)/ace/Module.i \ - $(ACE_ROOT)/ace/Module.cpp \ - $(ACE_ROOT)/ace/Stream_Modules.h \ - $(ACE_ROOT)/ace/Stream_Modules.cpp \ - $(ACE_ROOT)/ace/Svc_Handler.cpp \ - $(ACE_ROOT)/ace/Dynamic.h \ - $(ACE_ROOT)/ace/Dynamic.i - -.obj/StreamFactory.o .obj/StreamFactory.so .shobj/StreamFactory.o .shobj/StreamFactory.so: StreamFactory.cpp \ - StreamFactory.h \ - $(ACE_ROOT)/ace/pre.h \ - ACEXML_Export.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - XML_Types.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h \ - $(ACE_ROOT)/ace/Trace.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - $(ACE_ROOT)/ace/SString.i \ - FileCharStream.h \ - CharStream.h \ - Encoding.h \ - HttpCharStream.h \ - URL_Addr.h \ - $(ACE_ROOT)/ace/INET_Addr.h \ - $(ACE_ROOT)/ace/Addr.h $(ACE_ROOT)/ace/Addr.i \ - $(ACE_ROOT)/ace/INET_Addr.i \ - URL_Addr.inl \ - Mem_Map_Stream.h \ - $(ACE_ROOT)/ace/SOCK_Stream.h \ - $(ACE_ROOT)/ace/SOCK_IO.h \ - $(ACE_ROOT)/ace/SOCK.h \ - $(ACE_ROOT)/ace/IPC_SAP.h \ - $(ACE_ROOT)/ace/IPC_SAP.i \ - $(ACE_ROOT)/ace/SOCK.i \ - $(ACE_ROOT)/ace/SOCK_IO.i \ - $(ACE_ROOT)/ace/SOCK_Stream.i \ - $(ACE_ROOT)/ace/SOCK_Connector.h \ - $(ACE_ROOT)/ace/SOCK_Connector.i \ - $(ACE_ROOT)/ace/Connector.h \ - $(ACE_ROOT)/ace/Service_Object.h \ - $(ACE_ROOT)/ace/Shared_Object.h \ - $(ACE_ROOT)/ace/Shared_Object.i \ - $(ACE_ROOT)/ace/Svc_Conf_Tokens.h \ - $(ACE_ROOT)/ace/DLL.h \ - $(ACE_ROOT)/ace/Service_Object.i \ - $(ACE_ROOT)/ace/Map_Manager.h \ - $(ACE_ROOT)/ace/Map_Manager.i \ - $(ACE_ROOT)/ace/Map_Manager.cpp \ - $(ACE_ROOT)/ace/Service_Config.h \ - $(ACE_ROOT)/ace/Unbounded_Queue.h \ - $(ACE_ROOT)/ace/Unbounded_Queue.inl \ - $(ACE_ROOT)/ace/Unbounded_Queue.cpp \ - $(ACE_ROOT)/ace/XML_Svc_Conf.h \ - $(ACE_ROOT)/ace/Service_Config.i \ - $(ACE_ROOT)/ace/Reactor.h \ - $(ACE_ROOT)/ace/Handle_Set.h \ - $(ACE_ROOT)/ace/Handle_Set.i \ - $(ACE_ROOT)/ace/Timer_Queue.h \ - $(ACE_ROOT)/ace/Timer_Queue_T.h \ - $(ACE_ROOT)/ace/Test_and_Set.h \ - $(ACE_ROOT)/ace/Test_and_Set.i \ - $(ACE_ROOT)/ace/Test_and_Set.cpp \ - $(ACE_ROOT)/ace/Timer_Queue_T.i \ - $(ACE_ROOT)/ace/Timer_Queue_T.cpp \ - $(ACE_ROOT)/ace/Reactor.i \ - $(ACE_ROOT)/ace/Reactor_Impl.h \ - $(ACE_ROOT)/ace/Strategies_T.h \ - $(ACE_ROOT)/ace/Hash_Map_Manager_T.h \ - $(ACE_ROOT)/ace/Functor.h \ - $(ACE_ROOT)/ace/Functor.i \ - $(ACE_ROOT)/ace/Functor_T.h \ - $(ACE_ROOT)/ace/Functor_T.i \ - $(ACE_ROOT)/ace/Functor_T.cpp \ - $(ACE_ROOT)/ace/Hash_Map_Manager_T.i \ - $(ACE_ROOT)/ace/Hash_Map_Manager_T.cpp \ - $(ACE_ROOT)/ace/Thread_Manager.h \ - $(ACE_ROOT)/ace/Thread_Exit.h \ - $(ACE_ROOT)/ace/Thread_Control.h \ - $(ACE_ROOT)/ace/Thread_Control.inl \ - $(ACE_ROOT)/ace/Containers.h \ - $(ACE_ROOT)/ace/Containers.i \ - $(ACE_ROOT)/ace/Containers_T.h \ - $(ACE_ROOT)/ace/Array_Base.h \ - $(ACE_ROOT)/ace/Array_Base.inl \ - $(ACE_ROOT)/ace/Array_Base.cpp \ - $(ACE_ROOT)/ace/Containers_T.i \ - $(ACE_ROOT)/ace/Containers_T.cpp \ - $(ACE_ROOT)/ace/Singleton.h \ - $(ACE_ROOT)/ace/Singleton.i \ - $(ACE_ROOT)/ace/Singleton.cpp \ - $(ACE_ROOT)/ace/Object_Manager.h \ - $(ACE_ROOT)/ace/Object_Manager.i \ - $(ACE_ROOT)/ace/Managed_Object.h \ - $(ACE_ROOT)/ace/Managed_Object.i \ - $(ACE_ROOT)/ace/Managed_Object.cpp \ - $(ACE_ROOT)/ace/Framework_Component.h \ - $(ACE_ROOT)/ace/Framework_Component.inl \ - $(ACE_ROOT)/ace/Framework_Component_T.h \ - $(ACE_ROOT)/ace/Framework_Component_T.inl \ - $(ACE_ROOT)/ace/Framework_Component_T.cpp \ - $(ACE_ROOT)/ace/Thread_Manager.i \ - $(ACE_ROOT)/ace/Connection_Recycling_Strategy.h \ - $(ACE_ROOT)/ace/Recyclable.h \ - $(ACE_ROOT)/ace/Recyclable.inl \ - $(ACE_ROOT)/ace/Refcountable.h \ - $(ACE_ROOT)/ace/Refcountable.inl \ - $(ACE_ROOT)/ace/Hashable.h \ - $(ACE_ROOT)/ace/Hashable.inl \ - $(ACE_ROOT)/ace/Strategies_T.i \ - $(ACE_ROOT)/ace/Strategies_T.cpp \ - $(ACE_ROOT)/ace/Service_Repository.h \ - $(ACE_ROOT)/ace/Service_Repository.i \ - $(ACE_ROOT)/ace/Service_Types.h \ - $(ACE_ROOT)/ace/Service_Types.i \ - $(ACE_ROOT)/ace/WFMO_Reactor.h \ - $(ACE_ROOT)/ace/Synch_Options.h \ - $(ACE_ROOT)/ace/Synch_Options.i \ - $(ACE_ROOT)/ace/Connector.cpp \ - $(ACE_ROOT)/ace/Svc_Handler.h \ - $(ACE_ROOT)/ace/Task.h $(ACE_ROOT)/ace/Task.i \ - $(ACE_ROOT)/ace/Task_T.h \ - $(ACE_ROOT)/ace/Message_Queue.h \ - $(ACE_ROOT)/ace/Message_Block.h \ - $(ACE_ROOT)/ace/Message_Block.i \ - $(ACE_ROOT)/ace/Message_Block_T.h \ - $(ACE_ROOT)/ace/Message_Block_T.i \ - $(ACE_ROOT)/ace/Message_Block_T.cpp \ - $(ACE_ROOT)/ace/IO_Cntl_Msg.h \ - $(ACE_ROOT)/ace/Message_Queue_T.h \ - $(ACE_ROOT)/ace/Message_Queue_T.i \ - $(ACE_ROOT)/ace/Message_Queue_T.cpp \ - $(ACE_ROOT)/ace/Notification_Strategy.h \ - $(ACE_ROOT)/ace/Notification_Strategy.inl \ - $(ACE_ROOT)/ace/Message_Queue.i \ - $(ACE_ROOT)/ace/Task_T.i \ - $(ACE_ROOT)/ace/Task_T.cpp \ - $(ACE_ROOT)/ace/Module.h \ - $(ACE_ROOT)/ace/Module.i \ - $(ACE_ROOT)/ace/Module.cpp \ - $(ACE_ROOT)/ace/Stream_Modules.h \ - $(ACE_ROOT)/ace/Stream_Modules.cpp \ - $(ACE_ROOT)/ace/Svc_Handler.cpp \ - $(ACE_ROOT)/ace/Dynamic.h \ - $(ACE_ROOT)/ace/Dynamic.i - -.obj/Encoding.o .obj/Encoding.so .shobj/Encoding.o .shobj/Encoding.so: Encoding.cpp Encoding.h \ - $(ACE_ROOT)/ace/pre.h \ - ACEXML_Export.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - XML_Types.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h \ - $(ACE_ROOT)/ace/Trace.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - $(ACE_ROOT)/ace/SString.i - -# IF YOU PUT ANYTHING HERE IT WILL GO AWAY diff --git a/ACEXML/common/Makefile.ACEXML b/ACEXML/common/Makefile.ACEXML new file mode 100644 index 00000000000..2d92a03740c --- /dev/null +++ b/ACEXML/common/Makefile.ACEXML @@ -0,0 +1,79 @@ +#---------------------------------------------------------------------------- +# GNU Makefile +#---------------------------------------------------------------------------- +MAKEFILE = Makefile.ACEXML +DEPENDENCY_FILE = .depend.Makefile.ACEXML +LIB_UNCHECKED = libACEXML.a +SHLIB_UNCHECKED = libACEXML.$(SOEXT) + + + +FILES = \ + SAXExceptions \ + Attributes_Def_Builder \ + AttributesImpl \ + Transcode \ + Mem_Map_Stream \ + Validator \ + Exception \ + CharStream \ + XMLFilterImpl \ + InputSource \ + LocatorImpl \ + NamespaceSupport \ + URL_Addr \ + StrCharStream \ + DTD_Manager \ + DefaultHandler \ + Env \ + FileCharStream \ + Element_Def_Builder \ + StreamFactory \ + HttpCharStream \ + ZipCharStream \ + Encoding \ + XML_Codecs +#---------------------------------------------------------------------------- +# Include macros and targets +#---------------------------------------------------------------------------- + +LIB = $(LIB_UNCHECKED) +SHLIB = $(SHLIB_UNCHECKED) + +include $(ACE_ROOT)/include/makeinclude/wrapper_macros.GNU +LSRC = $(addsuffix .cpp, $(FILES)) +ACELIB = -lACE + +include $(ACE_ROOT)/include/makeinclude/macros.GNU +include $(ACE_ROOT)/include/makeinclude/rules.common.GNU +include $(ACE_ROOT)/include/makeinclude/rules.nonested.GNU +include $(ACE_ROOT)/include/makeinclude/rules.lib.GNU +include $(ACE_ROOT)/include/makeinclude/rules.local.GNU + +CPPFLAGS += -I../.. + + +ifeq ($(shared_libs),1) + ifneq ($(SHLIB),) + CPPFLAGS += -DACEXML_BUILD_DLL + endif +endif +ifeq ($(static_libs),1) + ifneq ($(LIB),) + CPPFLAGS += -DACE_AS_STATIC_LIBS + endif +endif + + +LDFLAGS += -L../../ace + + +#---------------------------------------------------------------------------- +# Local targets +#---------------------------------------------------------------------------- + +realclean: clean +ifneq ($(GENERATED_DIRTY),) + -$(RM) -r $(GENERATED_DIRTY) +endif + diff --git a/ACEXML/common/Makefile.ACEXML.bor b/ACEXML/common/Makefile.ACEXML.bor new file mode 100644 index 00000000000..43f03a33acc --- /dev/null +++ b/ACEXML/common/Makefile.ACEXML.bor @@ -0,0 +1,113 @@ +# Makefile for building the ACEXML library with Borland C++ Builder + +NAME = ACEXML + +NAME = ACEXML + + +OBJFILES = \ + $(OBJDIR)\AttributesImpl.obj \ + $(OBJDIR)\Attributes_Def_Builder.obj \ + $(OBJDIR)\CharStream.obj \ + $(OBJDIR)\DTD_Manager.obj \ + $(OBJDIR)\DefaultHandler.obj \ + $(OBJDIR)\Element_Def_Builder.obj \ + $(OBJDIR)\Encoding.obj \ + $(OBJDIR)\Env.obj \ + $(OBJDIR)\Exception.obj \ + $(OBJDIR)\FileCharStream.obj \ + $(OBJDIR)\HttpCharStream.obj \ + $(OBJDIR)\InputSource.obj \ + $(OBJDIR)\LocatorImpl.obj \ + $(OBJDIR)\Mem_Map_Stream.obj \ + $(OBJDIR)\NamespaceSupport.obj \ + $(OBJDIR)\SAXExceptions.obj \ + $(OBJDIR)\StrCharStream.obj \ + $(OBJDIR)\StreamFactory.obj \ + $(OBJDIR)\Transcode.obj \ + $(OBJDIR)\URL_Addr.obj \ + $(OBJDIR)\Validator.obj \ + $(OBJDIR)\XMLFilterImpl.obj \ + $(OBJDIR)\XML_Codecs.obj \ + $(OBJDIR)\ZipCharStream.obj + +EXTERNAL_LIBS = \ + \ + +LFLAGS = \ + -j..\..\ace\$(CONFIG_SUBDIR) -j..\..\ace \ + -L..\..\ace\$(CONFIG_SUBDIR) -L..\..\ace \ + -j$(CORE_BINDIR) \ + -L$(CORE_BINDIR) + +LIBFILES = \ + ACE$(LIB_DECORATOR).lib \ + $(EXTERNAL_LIBS) + + + +!ifdef STATIC +LIB_FLAGS = -DACE_AS_STATIC_LIBS +DLL_FLAGS = +!else +LIB_FLAGS = +DLL_FLAGS = -DACEXML_BUILD_DLL +!endif + +CFLAGS = \ + -I..\.. \ + $(LIB_FLAGS) \ + $(DLL_FLAGS) + +CPPDIR = . + +INCLUDES = \ + ACEXML_Export.h \ + Attributes.h \ + AttributesImpl.h \ + Attributes_Def_Builder.h \ + CharStream.h \ + ContentHandler.h \ + DTDHandler.h \ + DTD_Manager.h \ + DefaultHandler.h \ + Element_Def_Builder.h \ + Encoding.h \ + EntityResolver.h \ + Env.h \ + ErrorHandler.h \ + Exception.h \ + FileCharStream.h \ + HttpCharStream.h \ + InputSource.h \ + Locator.h \ + LocatorImpl.h \ + Mem_Map_Stream.h \ + NamespaceSupport.h \ + SAXExceptions.h \ + StrCharStream.h \ + StreamFactory.h \ + Transcode.h \ + URL_Addr.h \ + Validator.h \ + XMLFilter.h \ + XMLFilterImpl.h \ + XMLReader.h \ + XML_Codecs.h \ + XML_Macros.h \ + XML_Types.h \ + ZipCharStream.h \ + AttributesImpl.i \ + DefaultHandler.i \ + Env.i \ + Exception.i \ + LocatorImpl.i \ + NamespaceSupport.i \ + SAXExceptions.i \ + Transcode.i \ + URL_Addr.inl \ + XMLFilterImpl.i + +BASE_BINDIR = ..\..\bin + +!include <$(ACE_ROOT)\include\makeinclude\build_library.bor> diff --git a/ACEXML/common/Makefile.bor b/ACEXML/common/Makefile.bor index 8545b53d384..31b53535630 100644 --- a/ACEXML/common/Makefile.bor +++ b/ACEXML/common/Makefile.bor @@ -1,38 +1,20 @@ -# Makefile for building the XML library +#---------------------------------------------------------------------------- +# Borland Workspace +#---------------------------------------------------------------------------- -NAME = ACEXML +!include <$(ACE_ROOT)\include\makeinclude\make_flags.bor> -OBJFILES = \ - $(OBJDIR)\Attributes_Def_Builder.obj \ - $(OBJDIR)\AttributesImpl.obj \ - $(OBJDIR)\CharStream.obj \ - $(OBJDIR)\DefaultHandler.obj \ - $(OBJDIR)\DTD_Manager.obj \ - $(OBJDIR)\Element_Def_Builder.obj \ - $(OBJDIR)\Env.obj \ - $(OBJDIR)\Encoding.obj \ - $(OBJDIR)\Exception.obj \ - $(OBJDIR)\FileCharStream.obj \ - $(OBJDIR)\InputSource.obj \ - $(OBJDIR)\LocatorImpl.obj \ - $(OBJDIR)\NamespaceSupport.obj \ - $(OBJDIR)\SAXExceptions.obj \ - $(OBJDIR)\StrCharStream.obj \ - $(OBJDIR)\Transcode.obj \ - $(OBJDIR)\Validator.obj \ - $(OBJDIR)\XMLFilterImpl.obj \ - $(OBJDIR)\Mem_Map_Stream.obj \ - $(OBJDIR)\HttpCharStream.obj \ - $(OBJDIR)\URL_Addr.obj +all: + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ACEXML.bor all -CFLAGS = \ - $(ACE_CFLAGS) \ - $(ACE_XML_CFLAGS) \ - -DACEXML_BUILD_DLL +clean: + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ACEXML.bor clean -CPPDIR = .;.. +realclean: + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ACEXML.bor realclean -LIBFILES = \ - $(ACE_LIB) +install: + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ACEXML.bor install -!include <$(ACE_ROOT)\include\makeinclude\build_core_library.bor> +regenerate: + D:\Perl\bin\perl.exe D:\ACE_wrappers\bin\mwc.pl -type borland -recurse diff --git a/ACEXML/common/Mem_Map_Stream.cpp b/ACEXML/common/Mem_Map_Stream.cpp index 2513005e3bb..25f785d3b64 100644 --- a/ACEXML/common/Mem_Map_Stream.cpp +++ b/ACEXML/common/Mem_Map_Stream.cpp @@ -34,15 +34,13 @@ ACEXML_Mem_Map_Stream::get_char (void) { if (this->eof () && this->grow_file_and_remap () == -1) return EOF; - return *this->get_pos_++; } void ACEXML_Mem_Map_Stream::rewind (void) { - this->recv_pos_ = ACE_reinterpret_cast (char *, - this->mem_map_.addr ()); + this->recv_pos_ = ACE_reinterpret_cast (char *, this->mem_map_.addr ()); this->get_pos_ = this->recv_pos_; this->end_of_mapping_plus1_ = this->recv_pos_ + this->mem_map_.size (); } @@ -68,8 +66,10 @@ const char * ACEXML_Mem_Map_Stream::recv (size_t &len) { if (this->eof () && this->grow_file_and_remap () == -1) - return 0; - + { + len = 0; + return 0; + } const char *s = this->recv_pos_; this->seek (ACE_static_cast (off_t, len), SEEK_CUR); len = this->get_pos_ - s; @@ -188,31 +188,55 @@ ACEXML_Mem_Map_Stream::open (Connector *connector, int ACEXML_Mem_Map_Stream::grow_file_and_remap (void) { - char buf[BUFSIZ + 1]; + char buf[8192]; // Copy the next chunk of bytes from the socket into the temporary // file. ACE_Time_Value tv (ACE_DEFAULT_TIMEOUT); - - ssize_t n = this->svc_handler_->peer ().recv (buf, sizeof buf, 0, &tv); - if (n == -1) + ssize_t bytes = 0; + ssize_t n = 0; + while (1) { - ACE_ERROR ((LM_ERROR, "%p\n", "recv")); - return -1; + n = this->svc_handler_->peer ().recv (buf, sizeof buf, 0, &tv); + if (n == -1) + { + if (errno != EWOULDBLOCK) + { + ACE_ERROR ((LM_ERROR, "%p\n", "recv")); + return -1; + } + } + bytes += n; + if (n == 0 && !bytes) + return -1; + else if (n == 0) + break; + else if (ACE::write_n (this->mem_map_.handle (), buf, n) != n) + ACE_ERROR_RETURN ((LM_ERROR, + "%p\n", + "write_n"), + -1); } - else if (n == 0) - return -1; - else if (ACE::write_n (this->mem_map_.handle (), buf, n) != n) - ACE_ERROR_RETURN ((LM_ERROR, - "%p\n", - "write_n"), - -1); + +// ssize_t n = this->svc_handler_->peer ().recv (buf, sizeof buf, 0, &tv); +// if (n == -1) +// { +// ACE_ERROR ((LM_ERROR, "%p\n", "recv")); +// return -1; +// } +// else if (n == 0) +// return -1; +// else if (ACE::write_n (this->mem_map_.handle (), buf, n) != n) +// ACE_ERROR_RETURN ((LM_ERROR, +// "%p\n", +// "write_n"), +// -1); // Grow the memory-mapping to encompass the entire temporary file. if (this->mem_map_.map (-1, PROT_RDWR, - ACE_MAP_PRIVATE | ACE_MAP_FIXED, - ACE_DEFAULT_BASE_ADDR) == -1) + ACE_MAP_PRIVATE, + (void*)0) == -1) ACE_ERROR_RETURN ((LM_ERROR, "%p\n", "map"), @@ -220,8 +244,7 @@ ACEXML_Mem_Map_Stream::grow_file_and_remap (void) // MAP_FAILED is used as a "first time in" flag. if (this->recv_pos_ == MAP_FAILED) { - this->recv_pos_ = ACE_reinterpret_cast (char *, - this->mem_map_.addr ()); + this->recv_pos_ = ACE_reinterpret_cast (char *, this->mem_map_.addr ()); this->get_pos_ = this->recv_pos_; } diff --git a/ACEXML/common/NamespaceSupport.cpp b/ACEXML/common/NamespaceSupport.cpp index 5984b45c2e9..ba4ff11eccf 100644 --- a/ACEXML/common/NamespaceSupport.cpp +++ b/ACEXML/common/NamespaceSupport.cpp @@ -2,18 +2,15 @@ #include "ACEXML/common/NamespaceSupport.h" -static const ACEXML_Char ACEXML_XMLNS_PREFIX_name[] = {'x', 'm', 'l', 'n', 's', 0}; +static const ACEXML_Char ACEXML_XMLNS_PREFIX_name[] = ACE_TEXT ("xmlns"); + const ACEXML_Char *ACEXML_NamespaceSupport::XMLNS_PREFIX = ACEXML_XMLNS_PREFIX_name; static const ACEXML_Char ACEXML_DEFAULT_NS_PREFIX[] = {0}; -static const ACEXML_Char ACEXML_TABOO_NS_PREFIX[] = {'x', 'm', 'l', 0}; +static const ACEXML_Char ACEXML_TABOO_NS_PREFIX[] = ACE_TEXT ("xml"); -static const ACEXML_Char ACEXML_XMLNS_URI_name[] = { - 'h', 't', 't', 'p', ':', '/', '/', - 'w', 'w', 'w', '.', 'w', '3', '.', 'o', 'r', 'g', '/', - 'X', 'M', 'L', '/', '1', '9', '9', '8', '/', - 'n', 'a', 'm', 'e', 's', 'p', 'a', 'c', 'e', 0}; +static const ACEXML_Char ACEXML_XMLNS_URI_name[] = ACE_TEXT ("http://www.w3.org/XML/1998/namespace"); const ACEXML_Char *ACEXML_NamespaceSupport::XMLNS = ACEXML_XMLNS_URI_name; #if !defined (__ACEXML_INLINE__) @@ -62,14 +59,17 @@ ACEXML_Namespace_Context_Stack::pop (void) ACEXML_NamespaceSupport::ACEXML_NamespaceSupport (void) : ns_stack_ (), effective_context_ (0) +{} + +int +ACEXML_NamespaceSupport::init (void) { // @@ No way to tell if the new fails. - ACE_NEW (effective_context_, - ACEXML_NS_CONTEXT ()); + ACE_NEW_RETURN (effective_context_, ACEXML_NS_CONTEXT(), -1); ACEXML_String prefix (ACEXML_TABOO_NS_PREFIX, 0, 0); ACEXML_String uri (ACEXML_XMLNS_URI_name, 0, 0); - this->effective_context_->bind (prefix, uri); + return this->effective_context_->bind (prefix, uri); } ACEXML_NamespaceSupport::~ACEXML_NamespaceSupport (void) @@ -82,6 +82,9 @@ int ACEXML_NamespaceSupport::declarePrefix (const ACEXML_Char *prefix, const ACEXML_Char *uri) { + if (!prefix || !uri) + return -1; + // Unless predefined by w3.org(?) NS prefix can never start with // "xml". if (ACE_OS_String::strcmp (ACEXML_TABOO_NS_PREFIX, prefix) == 0) @@ -112,6 +115,9 @@ ACEXML_NamespaceSupport::getDeclaredPrefixes (ACEXML_STR_LIST &prefixes) const const ACEXML_Char * ACEXML_NamespaceSupport::getPrefix (const ACEXML_Char *uri) const { + if (!uri || *uri == 0) + return 0; + ACEXML_NS_CONTEXT_ENTRY *entry; for (ACEXML_NS_CONTEXT_ITER iter (*this->effective_context_); @@ -146,6 +152,9 @@ int ACEXML_NamespaceSupport::getPrefixes (const ACEXML_Char *uri, ACEXML_STR_LIST &prefixes) const { + if (!uri) + return -1; + ACEXML_NS_CONTEXT_ENTRY *entry; for (ACEXML_NS_CONTEXT_ITER iter (*this->effective_context_); @@ -163,6 +172,9 @@ ACEXML_NamespaceSupport::getPrefixes (const ACEXML_Char *uri, const ACEXML_Char * ACEXML_NamespaceSupport::getURI (const ACEXML_Char *prefix) const { + if (!prefix) + return 0; + ACEXML_NS_CONTEXT_ENTRY *entry; if (this->effective_context_->find (ACEXML_String (prefix, 0, 0), @@ -208,21 +220,18 @@ ACEXML_NamespaceSupport::processName (const ACEXML_Char *qName, const ACEXML_Char *&name, int is_attribute) const { - size_t qlen = ACE_OS_String::strlen (qName); + int qlen = ACE_static_cast (int, ACE_OS_String::strlen (qName)); int len = -1; - for (size_t i = 0; i < qlen; ++i) + for (int i = 0; i < qlen; ++i) if (qName [i] == ':') { - len = ACE_static_cast (int, i); + len = i; break; } ACEXML_String prefix; - if (len == -1) - { name = qName; - } else { prefix.set (qName, len, 1); @@ -236,21 +245,29 @@ ACEXML_NamespaceSupport::processName (const ACEXML_Char *qName, ACEXML_NS_CONTEXT_ENTRY *entry; - if (this->effective_context_->find (prefix, entry) == 0) - uri = entry->int_id_.c_str (); + if (prefix != ACEXML_DEFAULT_NS_PREFIX) + { + if (this->effective_context_->find (prefix, entry) == 0) + uri = entry->int_id_.c_str (); + else + { + uri = ACEXML_DEFAULT_NS_PREFIX; + return -1; + } + } else { uri = ACEXML_DEFAULT_NS_PREFIX; return -1; } - return 0; } int ACEXML_NamespaceSupport::reset (void) { - // Not implemented. + while (this->popContext() != -1) + ; return 0; } diff --git a/ACEXML/common/NamespaceSupport.h b/ACEXML/common/NamespaceSupport.h index 7d2c7bf10ac..df672884e61 100644 --- a/ACEXML/common/NamespaceSupport.h +++ b/ACEXML/common/NamespaceSupport.h @@ -5,6 +5,7 @@ * @file NamespaceSupport.h * * $Id$ + * $Id$ * * @author Nanbor Wang <nanbor@cs.wustl.edu> */ @@ -141,6 +142,11 @@ public: ~ACEXML_NamespaceSupport (void); /** + * Initialize the namespace support object + */ + int init(void); + + /** * XMLNS default prefix and URI strings. */ static const ACEXML_Char *XMLNS_PREFIX; @@ -211,7 +217,7 @@ public: /** * Reset this Namespace support object for reuse. - * @todo Not implemented. + * */ int reset (void); diff --git a/ACEXML/common/SAXExceptions.cpp b/ACEXML/common/SAXExceptions.cpp index fe0963cd169..4f56ed31d99 100644 --- a/ACEXML/common/SAXExceptions.cpp +++ b/ACEXML/common/SAXExceptions.cpp @@ -105,7 +105,7 @@ ACEXML_SAXException::is_a (const ACEXML_Char *name) void ACEXML_SAXException::print (void) { - ACE_DEBUG ((LM_ERROR, + ACE_ERROR ((LM_ERROR, ACE_TEXT ("ACEXML: (%P|%t) %s: %s\n"), this->exception_name_, this->message())); } @@ -249,7 +249,7 @@ ACEXML_SAXParseException::is_a (const ACEXML_Char *name) void ACEXML_SAXParseException::print (void) { - ACE_DEBUG ((LM_ERROR, + ACE_ERROR ((LM_ERROR, ACE_TEXT ("ACEXML: (%P|%t) %s: %s\n"), this->exception_name_, this->message())); } diff --git a/ACEXML/common/StrCharStream.cpp b/ACEXML/common/StrCharStream.cpp index 1a2ea6fe93b..db0c2c7761a 100644 --- a/ACEXML/common/StrCharStream.cpp +++ b/ACEXML/common/StrCharStream.cpp @@ -6,16 +6,10 @@ #include "ace/Log_Msg.h" ACEXML_StrCharStream::ACEXML_StrCharStream (void) - : start_ (0), ptr_ (0), end_ (0), encoding_ (0) + : start_ (0), ptr_ (0), end_ (0), encoding_ (0), name_ (0) { } -ACEXML_StrCharStream::ACEXML_StrCharStream (const ACEXML_Char *str) - : start_ (0), ptr_ (0), end_ (0), encoding_ (0) -{ - this->open (str); -} - ACEXML_StrCharStream::~ACEXML_StrCharStream (void) { @@ -23,20 +17,17 @@ ACEXML_StrCharStream::~ACEXML_StrCharStream (void) } int -ACEXML_StrCharStream::open (const ACEXML_Char *str) +ACEXML_StrCharStream::open (const ACEXML_Char *str, const ACEXML_Char* name) { - delete[] this->start_; - delete[] this->encoding_; - if (str != 0 && (this->start_ = ACE::strnew (str)) != 0) + if (str != 0 && name != 0 + && (this->start_ = ACE::strnew (str)) != 0 + && (this->name_ = ACE::strnew (name)) != 0) { this->ptr_ = this->start_; this->end_ = this->start_ + ACE_OS_String::strlen (this->start_); - this->determine_encoding(); - return 0; + return this->determine_encoding(); } - - this->start_ = this->ptr_ = this->end_ = 0; return -1; // Invalid string passed. } @@ -53,6 +44,9 @@ ACEXML_StrCharStream::close (void) { delete[] this->start_; delete[] this->encoding_; + this->encoding_ = 0; + delete[] this->name_; + this->name_ = 0; this->start_ = this->ptr_ = this->end_ = 0; return 0; } @@ -60,26 +54,20 @@ ACEXML_StrCharStream::close (void) int ACEXML_StrCharStream::determine_encoding (void) { - char input[4]; - int retval = 0; + if (this->start_ == 0) + return -1; + char input[4] = {0,0,0,0}; char* sptr = (char*)this->start_; int i = 0; for ( ; i < 4 && sptr != (char*)this->end_; ++sptr, ++i) - { - retval = input[i] = *sptr; - } - if (i < 4) - return -1; + input[i] = *sptr; const ACEXML_Char* temp = ACEXML_Encoding::get_encoding (input); if (!temp) return -1; - if (ACE_OS::strcmp (temp, - ACEXML_Encoding::encoding_names_[ACEXML_Encoding::OTHER]) == 0) - return -1; else { this->encoding_ = ACE::strnew (temp); - ACE_DEBUG ((LM_DEBUG, "String's encoding is %s\n", this->encoding_)); + // ACE_DEBUG ((LM_DEBUG, "String's encoding is %s\n", this->encoding_)); } return 0; } @@ -96,23 +84,19 @@ ACEXML_StrCharStream::get (ACEXML_Char& ch) if (this->start_ != 0 && this->ptr_ != this->end_) { ch = *this->ptr_++; - return 0; } - return -1; } int -ACEXML_StrCharStream::read (ACEXML_Char *str, - size_t len) +ACEXML_StrCharStream::read (ACEXML_Char *str, size_t len) { if (this->start_ != 0 && this->ptr_ != this->end_) { - if ((int) len > this->end_ - this->ptr_) + if (len * sizeof (ACEXML_Char) > (size_t) (this->end_ - this->ptr_)) len = this->end_ - this->ptr_; - ACE_OS_String::strncpy (str, this->ptr_, len); this->ptr_ += len; return ACE_static_cast (int, len); @@ -133,3 +117,9 @@ ACEXML_StrCharStream::getEncoding (void) { return this->encoding_; } + +const ACEXML_Char* +ACEXML_StrCharStream::getSystemId(void) +{ + return this->name_; +} diff --git a/ACEXML/common/StrCharStream.h b/ACEXML/common/StrCharStream.h index 6321decb9a2..08b7bdbef9b 100644 --- a/ACEXML/common/StrCharStream.h +++ b/ACEXML/common/StrCharStream.h @@ -34,14 +34,11 @@ public: /// Default constructor. ACEXML_StrCharStream (void); - /// Initializing Constructor. - ACEXML_StrCharStream (const ACEXML_Char *str); - /// Destructor virtual ~ACEXML_StrCharStream (void); - /// Initializing and reset the StrCharStream with @a str. - int open (const ACEXML_Char *str); + /// Initializing StrCharStream with @a str and @a name + int open (const ACEXML_Char *str, const ACEXML_Char* name); /** * Returns the available ACEXML_Char in the buffer. -1 @@ -68,8 +65,7 @@ public: /** * Read the next batch of ACEXML_Char strings */ - virtual int read (ACEXML_Char *str, - size_t len); + virtual int read (ACEXML_Char *str, size_t len); /** * Peek the next ACEXML_Char in the CharStream. Return the @@ -82,6 +78,11 @@ public: */ virtual const ACEXML_Char *getEncoding (void); + /* + * Get the systemId for the underlying CharStream + */ + virtual const ACEXML_Char* getSystemId (void); + /** * Resets the pointer to the beginning of the stream. */ @@ -92,6 +93,7 @@ private: ACEXML_Char *ptr_; ACEXML_Char *end_; ACEXML_Char* encoding_; + ACEXML_Char* name_; }; diff --git a/ACEXML/common/StreamFactory.cpp b/ACEXML/common/StreamFactory.cpp index 80edc8a265f..f97e8617bda 100644 --- a/ACEXML/common/StreamFactory.cpp +++ b/ACEXML/common/StreamFactory.cpp @@ -4,6 +4,10 @@ #include "ACEXML/common/FileCharStream.h" #include "ACEXML/common/HttpCharStream.h" +#ifdef ACEXML_HAS_ZZIPLIB +#include "ACEXML/common/ZipCharStream.h" +#endif /* ACEXML_HAS_ZZIPLIB */ + ACE_RCSID (common, StreamFactory, "$Id$") ACEXML_CharStream* @@ -11,7 +15,6 @@ ACEXML_StreamFactory::create_stream (const ACEXML_Char* uri) { if (uri == 0) return 0; - ACEXML_FileCharStream* fstream = 0; ACEXML_HttpCharStream* hstream = 0; @@ -24,17 +27,25 @@ ACEXML_StreamFactory::create_stream (const ACEXML_Char* uri) ACE_NEW_RETURN (hstream, ACEXML_HttpCharStream, 0); if (hstream->open (uri) != -1) return hstream; - else - return 0; } else { + if (ACE_OS::strstr (uri, ACE_TEXT ("file://")) != 0) + uri += 7; // Skip over file:// ACE_NEW_RETURN (fstream, ACEXML_FileCharStream, 0); if (fstream->open (uri) != -1) return fstream; +#ifdef ACEXML_HAS_ZZIPLIB else - return 0; + { + ACEXML_ZipCharStream* zstream = 0; + ACE_NEW_RETURN (zstream, ACEXML_ZipCharStream, 0); + if (zstream->open (uri) != -1) + return zstream; + } +#endif /* ACEXML_HAS_ZZIPLIB */ } + return 0; } ACEXML_StreamFactory::~ACEXML_StreamFactory () diff --git a/ACEXML/common/Transcode.cpp b/ACEXML/common/Transcode.cpp index ed0a9494d25..bbc434e49d6 100644 --- a/ACEXML/common/Transcode.cpp +++ b/ACEXML/common/Transcode.cpp @@ -7,6 +7,239 @@ #endif /* __ACEXML_INLINE__ */ int +ACEXML_Transcoder::utf162utf8 (ACEXML_UTF16 src, + ACEXML_UTF8 *dst, + size_t len) +{ + // Check for valid argument first... + + if (dst == 0) + return INVALID_ARGS; + + if (src < 0x80) + { + if (len < 1) + return DESTINATION_TOO_SHORT; + + *dst = ACE_static_cast (ACEXML_UTF8, src); + return 1; + } + else if (src < 0x800) + { + if (len < 2) + return DESTINATION_TOO_SHORT; + + *dst = 0xc0 | (src / 0x40); + *(dst+1) = 0x80 | (src % 0x40); + return 2; + } + else + { + if (len < 3) + return DESTINATION_TOO_SHORT; + + // Surrogates (0xD800 - 0xDFFF) are not valid unicode values + if (src >= 0xD800 && src < 0xE000) + return IS_SURROGATE; + + *dst = 0xe0 | (src / 0x1000); + *(dst+1) = 0x80 | ((src % 0x1000) / 0x40); + *(dst+2) = 0x80 | (src % 0x40); + return 3; + } + ACE_NOTREACHED (return NON_UNICODE;) + } + +int +ACEXML_Transcoder::ucs42utf8 (ACEXML_UCS4 src, + ACEXML_UTF8 *dst, + size_t len) +{ + if (src < 0x10000) + { + int retv = ACEXML_Transcoder::utf162utf8 + (ACE_static_cast (ACEXML_UTF16, src), + dst, len); + return (retv == IS_SURROGATE ? NON_UNICODE : retv); + } + else if (src >= 0x100000 && src < 0x110000) + { + if (len < 4) + return DESTINATION_TOO_SHORT; + + if (dst == 0) + return INVALID_ARGS; + + *dst = 0xf0 | (src / 0x40000); + *(dst+1) = 0x80 | ((src % 0x40000) / 0x1000); + *(dst+2) = 0x80 | ((src % 0x1000) / 0x40); + *(dst+3) = 0x80 | (src % 0x40); + return 4; + } + return NON_UNICODE; +} + + +int +ACEXML_Transcoder::ucs42utf16 (ACEXML_UCS4 src, + ACEXML_UTF16 *dst, + size_t len) +{ + if (dst == 0) + return INVALID_ARGS; + + if (src < 0x10000) + { + if (len < 1) + return DESTINATION_TOO_SHORT; + + if (src >= 0xD800 && src < 0xE000) + return NON_UNICODE; // Surrogates are not valid unicode value + + *dst = ACE_static_cast (ACEXML_UTF16, src); + return 1; + } + else if (src >= 0x100000 && src < 0x110000) + // Scalar values are encoded into surrogates + { + if (len < 2) + return DESTINATION_TOO_SHORT; + + *dst = 0xD800 | (src / 0x400); + *(dst+1) = 0xDC00 | (src % 0x400); + return 2; + } + + return NON_UNICODE; +} + +int +ACEXML_Transcoder::surrogate2utf8 (ACEXML_UTF16 high, + ACEXML_UTF16 low, + ACEXML_UTF8 *dst, + size_t len) +{ + if (len < 3) + return DESTINATION_TOO_SHORT; + + if (dst == 0 || + (high >= 0xD800 && high < 0xDC00) || + (low >= 0xDC00 && low < 0xE000)) + return INVALID_ARGS; + + ACEXML_UCS4 src = (high - 0xD800) * 0x400 + (low - 0xDC00) + 0x10000; + *dst = 0xD800 | (src / 0x400); + *(dst+1) = 0xDC00 | (src % 0x400); + return 2; +} + +int +ACEXML_Transcoder::surrogate2ucs4 (ACEXML_UTF16 high, + ACEXML_UTF16 low, + ACEXML_UCS4 &dst) +{ + if ((high >= 0xD800 && high < 0xDC00) || + (low >= 0xDC00 && low < 0xE000)) + return INVALID_ARGS; + + dst = (high - 0xD800) * 0x400 + (low - 0xDC00) + 0x10000; + return SUCCESS; +} + +int +ACEXML_Transcoder::utf82ucs4 (const ACEXML_UTF8 *the_src, + size_t len, + ACEXML_UCS4 &dst) +{ + if (the_src == 0) + return INVALID_ARGS; + + const unsigned char *src = ACE_reinterpret_cast (const unsigned char *, + the_src); + + size_t forward = 1; + + if (forward > len) + return END_OF_SOURCE; + + if (ACE_static_cast (unsigned char, *src) < 0x80) + dst = *src; + else if ((*src & 0xE0) == 0xC0) + { + dst = (*(src++) & 0x1f) * 0x40; + if (++forward > len) + return END_OF_SOURCE; + if ((*src & 0xC0) != 0x80) + return NON_UNICODE; // Error transcoding unicode scalar + dst += *src & 0x3f; + } + else if ((*src & 0xF0) == 0xE0) + { + dst = (*src++ & 0x0f) * 0x40; + if (++forward > len) + return END_OF_SOURCE; + if ((*src & 0xC0) != 0x80) + return NON_UNICODE; + dst = (dst + (*src++ & 0x3f)) * 0x40; + if (++forward > len) + return END_OF_SOURCE; + if ((*src & 0xC0) != 0x80) + return NON_UNICODE; + dst += *src & 0x3f; + } + else if ((*src & 0xF8) == 0xF0) + { + dst = (*src++ & 0x0f) * 0x40; + if (++forward > len) + return END_OF_SOURCE; + if ((*src & 0xC0) != 0x80) + return NON_UNICODE; + dst = (dst + (*src++ & 0x3f)) * 0x40; + if (++forward > len) + return END_OF_SOURCE; + if ((*src & 0xC0) != 0x80) + return NON_UNICODE; + dst = (dst + (*src++ & 0x3f)) * 0x40; + if (++forward > len) + return END_OF_SOURCE; + if ((*src & 0xC0) != 0x80) + return NON_UNICODE; + dst += *src & 0x3f; + } + else + return NON_UNICODE; + + return forward; +} + +int +ACEXML_Transcoder::utf162ucs4 (const ACEXML_UTF16 *src, + size_t len, + ACEXML_UCS4 &dst) +{ + if (src == 0) + return INVALID_ARGS; + + size_t forward = 1; + if (*src >= 0xDC00 && *src < 0xE000) + { + if (len < 2) + return END_OF_SOURCE; + return ACEXML_Transcoder::surrogate2ucs4 (*src, + *(src+1), + dst); + } + else + { + if (len < 1) + return END_OF_SOURCE; + dst = *src; + } + + return forward; +} + +int ACEXML_Transcoder::utf8s2utf16s (const ACEXML_UTF8 *src, ACEXML_UTF16 *dst, size_t len) diff --git a/ACEXML/common/Transcode.h b/ACEXML/common/Transcode.h index 427784891db..904d699ab56 100644 --- a/ACEXML/common/Transcode.h +++ b/ACEXML/common/Transcode.h @@ -58,7 +58,7 @@ public: * Convert a UTF-16 character into a string in UTF-8 encoding. * * @return number of characters the function uses to store the - * converted string if succeeds or one of the error STATUS + * converted string if it succeeds or one of the error STATUS * otherwise. */ static int utf162utf8 (ACEXML_UTF16 src, @@ -69,7 +69,7 @@ public: * Convert a UCS-4 character into a string in UTF-8 encoding. * * @return number of characters the function uses to store the - * converted string if succeeds or one of the error STATUS + * converted string if it succeeds or one of the error STATUS * otherwise. */ static int ucs42utf8 (ACEXML_UCS4 src, @@ -80,7 +80,7 @@ public: * Convert a UCS-4 character into a string in UTF-16 encoding. * * @return number of characters the function uses to store the - * converted string if succeeds or one of the error STATUS + * converted string if it succeeds or one of the error STATUS * otherwise. */ static int ucs42utf16 (ACEXML_UCS4 src, @@ -91,7 +91,7 @@ public: * Convert a UTF-16 surrogate character pair into a string in UTF-8 encoding. * * @return number of characters the function uses to store the - * converted string if succeeds or one of the error STATUS + * converted string if it succeeds or one of the error STATUS * otherwise. */ static int surrogate2utf8 (ACEXML_UTF16 high, @@ -102,7 +102,7 @@ public: /* * Convert a UTF-16 surrogate character pair into a UCS-4 character. * - * @return SUCCESS if succeeds or one of the error STATUS + * @return SUCCESS if it succeeds or one of the error STATUS * otherwise. */ static int surrogate2ucs4 (ACEXML_UTF16 high, @@ -114,7 +114,7 @@ public: * into a UCS-4 character. * * @return number of characters the function consumed from the - * UTF-8 string if succeeds or one of the error STATUS + * UTF-8 string if it succeeds or one of the error STATUS * otherwise. */ static int utf82ucs4 (const ACEXML_UTF8 *src, @@ -126,7 +126,7 @@ public: * into a UCS-4 character. * * @return number of characters the function consumed from the - * UTF-16 string if succeeds or one of the error STATUS + * UTF-16 string if it succeeds or one of the error STATUS * otherwise. */ static int utf162ucs4 (const ACEXML_UTF16 *src, @@ -146,7 +146,7 @@ public: * @param len The length of @a dst string. * * @return number of characters the function consumed from the - * UTF-8 string if succeeds or one of the error STATUS + * UTF-8 string if it succeeds or one of the error STATUS * otherwise. */ static int utf8s2utf16s (const ACEXML_UTF8 *src, @@ -159,7 +159,7 @@ public: * @param len The length of @a dst string. * * @return number of characters the function uses in - * UTF-8 string if succeeds or one of the error STATUS + * UTF-8 string if it succeeds or one of the error STATUS * otherwise. */ static int utf16s2utf8s (const ACEXML_UTF16 *src, diff --git a/ACEXML/common/Transcode.i b/ACEXML/common/Transcode.i index a267fa8ec57..77b4466a3cb 100644 --- a/ACEXML/common/Transcode.i +++ b/ACEXML/common/Transcode.i @@ -1,234 +1 @@ // -*- C++ -*- $Id$ - -ACEXML_INLINE int -ACEXML_Transcoder::utf162utf8 (ACEXML_UTF16 src, - ACEXML_UTF8 *dst, - size_t len) -{ - // Check for valid argument first... - - if (dst == 0) - return INVALID_ARGS; - - if (src < 0x80) - { - if (len < 1) - return DESTINATION_TOO_SHORT; - - *dst = ACE_static_cast (ACEXML_UTF8, src); - return 1; - } - else if (src < 0x800) - { - if (len < 2) - return DESTINATION_TOO_SHORT; - - *dst = 0xc0 | (src / 0x40); - *(dst+1) = 0x80 | (src % 0x40); - return 2; - } - else - { - if (len < 3) - return DESTINATION_TOO_SHORT; - - // Surrogates (0xD800 - 0xDFFF) are not valid unicode values - if (src >= 0xD800 && src < 0xE000) - return IS_SURROGATE; - - *dst = 0xe0 | (src / 0x1000); - *(dst+1) = 0x80 | ((src % 0x1000) / 0x40); - *(dst+2) = 0x80 | (src % 0x40); - return 3; - } - ACE_NOTREACHED (return NON_UNICODE;) -} - -ACEXML_INLINE int -ACEXML_Transcoder::ucs42utf8 (ACEXML_UCS4 src, - ACEXML_UTF8 *dst, - size_t len) -{ - if (src < 0x10000) - { - int retv = ACEXML_Transcoder::utf162utf8 - (ACE_static_cast (ACEXML_UTF16, src), - dst, len); - return (retv == IS_SURROGATE ? NON_UNICODE : retv); - } - else if (src >= 0x100000 && src < 0x110000) - { - if (len < 4) - return DESTINATION_TOO_SHORT; - - if (dst == 0) - return INVALID_ARGS; - - *dst = 0xf0 | (src / 0x40000); - *(dst+1) = 0x80 | ((src % 0x40000) / 0x1000); - *(dst+2) = 0x80 | ((src % 0x1000) / 0x40); - *(dst+3) = 0x80 | (src % 0x40); - return 4; - } - return NON_UNICODE; -} - - -ACEXML_INLINE int -ACEXML_Transcoder::ucs42utf16 (ACEXML_UCS4 src, - ACEXML_UTF16 *dst, - size_t len) -{ - if (dst == 0) - return INVALID_ARGS; - - if (src < 0x10000) - { - if (len < 1) - return DESTINATION_TOO_SHORT; - - if (src >= 0xD800 && src < 0xE000) - return NON_UNICODE; // Surrogates are not valid unicode value - - *dst = ACE_static_cast (ACEXML_UTF16, src); - return 1; - } - else if (src >= 0x100000 && src < 0x110000) - // Scalar values are encoded into surrogates - { - if (len < 2) - return DESTINATION_TOO_SHORT; - - *dst = 0xD800 | (src / 0x400); - *(dst+1) = 0xDC00 | (src % 0x400); - return 2; - } - - return NON_UNICODE; -} - -ACEXML_INLINE int -ACEXML_Transcoder::surrogate2utf8 (ACEXML_UTF16 high, - ACEXML_UTF16 low, - ACEXML_UTF8 *dst, - size_t len) -{ - if (len < 3) - return DESTINATION_TOO_SHORT; - - if (dst == 0 || - (high >= 0xD800 && high < 0xDC00) || - (low >= 0xDC00 && low < 0xE000)) - return INVALID_ARGS; - - ACEXML_UCS4 src = (high - 0xD800) * 0x400 + (low - 0xDC00) + 0x10000; - *dst = 0xD800 | (src / 0x400); - *(dst+1) = 0xDC00 | (src % 0x400); - return 2; -} - -ACEXML_INLINE int -ACEXML_Transcoder::surrogate2ucs4 (ACEXML_UTF16 high, - ACEXML_UTF16 low, - ACEXML_UCS4 &dst) -{ - if ((high >= 0xD800 && high < 0xDC00) || - (low >= 0xDC00 && low < 0xE000)) - return INVALID_ARGS; - - dst = (high - 0xD800) * 0x400 + (low - 0xDC00) + 0x10000; - return SUCCESS; -} - -ACEXML_INLINE int -ACEXML_Transcoder::utf82ucs4 (const ACEXML_UTF8 *the_src, - size_t len, - ACEXML_UCS4 &dst) -{ - if (the_src == 0) - return INVALID_ARGS; - - const unsigned char *src = ACE_reinterpret_cast (const unsigned char *, - the_src); - - size_t forward = 1; - - if (forward > len) - return END_OF_SOURCE; - - if (ACE_static_cast (unsigned char, *src) < 0x80) - dst = *src; - else if ((*src & 0xE0) == 0xC0) - { - dst = (*(src++) & 0x1f) * 0x40; - if (++forward > len) - return END_OF_SOURCE; - if ((*src & 0xC0) != 0x80) - return NON_UNICODE; // Error transcoding unicode scalar - dst += *src & 0x3f; - } - else if ((*src & 0xF0) == 0xE0) - { - dst = (*src++ & 0x0f) * 0x40; - if (++forward > len) - return END_OF_SOURCE; - if ((*src & 0xC0) != 0x80) - return NON_UNICODE; - dst = (dst + (*src++ & 0x3f)) * 0x40; - if (++forward > len) - return END_OF_SOURCE; - if ((*src & 0xC0) != 0x80) - return NON_UNICODE; - dst += *src & 0x3f; - } - else if ((*src & 0xF8) == 0xF0) - { - dst = (*src++ & 0x0f) * 0x40; - if (++forward > len) - return END_OF_SOURCE; - if ((*src & 0xC0) != 0x80) - return NON_UNICODE; - dst = (dst + (*src++ & 0x3f)) * 0x40; - if (++forward > len) - return END_OF_SOURCE; - if ((*src & 0xC0) != 0x80) - return NON_UNICODE; - dst = (dst + (*src++ & 0x3f)) * 0x40; - if (++forward > len) - return END_OF_SOURCE; - if ((*src & 0xC0) != 0x80) - return NON_UNICODE; - dst += *src & 0x3f; - } - else - return NON_UNICODE; - - return ACE_static_cast (int, forward); -} - -ACEXML_INLINE int -ACEXML_Transcoder::utf162ucs4 (const ACEXML_UTF16 *src, - size_t len, - ACEXML_UCS4 &dst) -{ - if (src == 0) - return INVALID_ARGS; - - size_t forward = 1; - if (*src >= 0xDC00 && *src < 0xE000) - { - if (len < 2) - return END_OF_SOURCE; - return ACEXML_Transcoder::surrogate2ucs4 (*src, - *(src+1), - dst); - } - else - { - if (len < 1) - return END_OF_SOURCE; - dst = *src; - } - - return ACE_static_cast (int, forward); -} diff --git a/ACEXML/common/ZipCharStream.cpp b/ACEXML/common/ZipCharStream.cpp new file mode 100644 index 00000000000..3a4c1c7f334 --- /dev/null +++ b/ACEXML/common/ZipCharStream.cpp @@ -0,0 +1,247 @@ +// $Id$ + +#ifdef ACEXML_HAS_ZZIPLIB + +#include "ACEXML/common/ZipCharStream.h" +#include "ace/ACE.h" + + +ACEXML_ZipCharStream::ACEXML_ZipCharStream (void) + : filename_ (0), encoding_ (0), size_ (0), infile_ (0), pos_ (0), + limit_ (0) +{ +} + +ACEXML_ZipCharStream::~ACEXML_ZipCharStream (void) +{ + this->close(); +} + +int +ACEXML_ZipCharStream::open (const ACEXML_Char *name) +{ + delete[] this->filename_; + this->filename_ = 0; + + delete[] this->encoding_; + this->encoding_ = 0; + + this->infile_ = zzip_fopen (name, ACE_TEXT ("r")); + if (this->infile_ == 0) + return -1; + + this->filename_ = ACE::strnew (ACE::basename (name)); + return this->determine_encoding(); +} + +int +ACEXML_ZipCharStream::determine_encoding (void) +{ + if (this->infile_ == 0) + return -1; + char input[4]; + int i = 0; + for (; i < 4 && (input[i] = this->peekchar_i(i)) > 0; ++i) + ; + if (i < 4) + return -1; + const ACEXML_Char* temp = ACEXML_Encoding::get_encoding (input); + if (!temp) + return -1; + else + { + this->encoding_ = ACE::strnew (temp); + // ACE_DEBUG ((LM_DEBUG, ACE_TEXT ("File's encoding is %s\n"), +// this->encoding_)); + } + // Move over the byte-order-mark if present. + char ch; + for (int j = 0; j < 3; ++j) + { + if ((ch = this->peekchar_i()) < 0) + return -1; + if (ch == '\xFF' || ch == '\xFE' || ch == '\xEF' || ch == '\xBB' || + ch == '\xBF') + this->get(ch); + else + break; + } + return 0; +} + +void +ACEXML_ZipCharStream::rewind() +{ + if (this->infile_ == 0) + return; + zzip_rewind (this->infile_); +} + +int +ACEXML_ZipCharStream::available (void) +{ + if (this->infile_ == 0) + return -1; + long curr; + if ((curr = zzip_tell (this->infile_)) < 0) + return -1; + return (this->size_ - curr); +} + +int +ACEXML_ZipCharStream::close (void) +{ + if (this->infile_ != 0) + { + zzip_close (this->infile_); + this->infile_ = 0; + } + delete[] this->filename_; + this->filename_ = 0; + delete[] this->encoding_; + this->encoding_ = 0; + this->size_ = 0; + this->pos_ = 0; + this->limit_ = 0; + return 0; +} + + +int +ACEXML_ZipCharStream::getchar_i (char& ch) +{ + if (this->infile_ == 0) + return -1; + + if (this->pos_ < this->limit_) + { + ch = this->buf_[this->pos_++]; + return 0; + } + this->limit_ = zzip_read (this->infile_, this->buf_, sizeof (this->buf_)); + if (this->limit_ == 0) + return -1; + this->pos_ = 0; + ch = this->buf_[this->pos_++]; + return 0; +} + +int +ACEXML_ZipCharStream::peekchar_i (off_t offset) +{ + if (this->infile_ == 0) + return -1; + + if (offset > (off_t) sizeof (this->buf_)) + return -1; + if (this->pos_ + offset < this->limit_) + return this->buf_[this->pos_ + offset]; + int i = 0; + for (; this->pos_ < this->limit_; ++this->pos_, ++i) + this->buf_[i] = this->buf_[this->pos_]; + this->limit_ = zzip_read (this->infile_, this->buf_ + i, + sizeof (this->buf_) - i); + this->limit_ += i; + if (this->limit_ == 0) + return -1; + this->pos_ = 0; + return this->buf_[this->pos_ + offset]; +} + +int +ACEXML_ZipCharStream::read (ACEXML_Char *str, size_t len) +{ + if (this->infile_ == 0) + return -1; + + size_t i = 0; + for (; i < len && this->pos_ < this->limit_; ++i) + str[i] = this->buf_[this->pos_++]; + if (i == len) + return len; + len = len - i; + this->pos_ = 0; + this->limit_ = 0; + int bytes = zzip_fread (str + i, sizeof (ACEXML_Char), len, this->infile_); + return (bytes + i); +} + +int +ACEXML_ZipCharStream::get (ACEXML_Char& ch) +{ +#if defined (ACE_USES_WCHAR) + return this->get_i (ch); +#else + return this->getchar_i (ch); +#endif /* ACE_USES_WCHAR */ +} + + +int +ACEXML_ZipCharStream::peek (void) +{ +#if defined (ACE_USES_WCHAR) + return this->peek_i(); +#else + return this->peekchar_i(); +#endif /* ACE_USES_WCHAR */ +} + +const ACEXML_Char* +ACEXML_ZipCharStream::getEncoding (void) +{ + return this->encoding_; +} + +const ACEXML_Char* +ACEXML_ZipCharStream::getSystemId (void) +{ + return this->filename_; +} + +#if defined (ACE_USES_WCHAR) +int +ACEXML_ZipCharStream::get_i (ACEXML_Char& ch) +{ + if (ACE_OS::strcmp (this->encoding_, ACE_TEXT ("UTF-8")) == 0) + return this->getchar_i (ch); + + int BE = (ACE_OS::strcmp (this->encoding_, + ACE_TEXT ("UTF-16BE")) == 0) ? 1 : 0; + ACEXML_Char input[2]; + int i = 0; + for (; i < 2 && (this->getchar_i (input[i]) == 0); ++i) + ; + if (i < 2) + { + ch = 0; + return -1; + } + ch = BE ? input[0] << 8 | input[1] : input[1] << 8 | input[0]; + return 0; +} + +int +ACEXML_ZipCharStream::peek_i (void) +{ + + // If we are reading a UTF-8 encoded file, just use the plain unget. + if (ACE_OS::strcmp (this->encoding_, ACE_TEXT ("UTF-8")) == 0) + return this->peekchar_i(); + + // Peek into the stream. This reads two characters off the stream, keeps + // it in peek_. + int BE = (ACE_OS::strcmp (this->encoding_, + ACE_TEXT ("UTF-16BE")) == 0) ? 1 : 0; + + ACEXML_Char input[2]; + int i = 0; + for (; i < 2 && (input[i] = this->peekchar_i (i)) > 0; ++i) + ; + if (i < 2) + return -1; + return (BE ? input[0] << 8 | input[1] : input[1] << 8 | input[0]); +} +#endif /* ACE_USES_WCHAR */ + +#endif /* ACEXML_HAS_ZZIPLIB */ diff --git a/ACEXML/common/ZipCharStream.h b/ACEXML/common/ZipCharStream.h new file mode 100644 index 00000000000..46a2e86930f --- /dev/null +++ b/ACEXML/common/ZipCharStream.h @@ -0,0 +1,150 @@ +// -*- C++ -*- + +//============================================================================= +/** + * @file ZipCharStream.h + * + * $Id$ + * + * @author Krishnakumar B <kitty@cs.wustl.edu> + */ +//============================================================================= + +#ifndef _ACEXML_ZIPCHARSTREAM_H_ +#define _ACEXML_ZIPCHARSTREAM_H_ + +#ifdef ACEXML_HAS_ZZIPLIB + +#include "ace/pre.h" +#include "ACEXML/common/ACEXML_Export.h" + +#if !defined (ACE_LACKS_PRAGMA_ONCE) +#pragma once +#endif /* ACE_LACKS_PRAGMA_ONCE */ + +#include "ACEXML/common/CharStream.h" +#include "ACEXML/common/Encoding.h" +#include "zziplib.h" + +// Ugly wart to get aroung a macro version of read defined in zziplib.h. Evil... +#ifdef read +#define ACEXML_save_read read +#undef read +#endif + +/** + * @class ACEXML_ZipCharStream ZipCharStream.h "ACEXML/common/ZipCharStream.h" + * + * An implementation of ACEXML_CharStream for reading input from a ZIP archive. + */ +class ACEXML_Export ACEXML_ZipCharStream : public ACEXML_CharStream +{ +public: + /// Default constructor. + ACEXML_ZipCharStream (void); + + /// Destructor + virtual ~ACEXML_ZipCharStream (void); + + /// Open a file. + int open (const ACEXML_Char *name); + + /** + * Returns the available ACEXML_Char in the buffer. -1 + * if the object is not initialized properly. + */ + virtual int available (void); + + /** + * Close this stream and release all resources used by it. + */ + virtual int close (void); + + /** + * Read the next ACEXML_Char. Return -1 if we are not able to + * return an ACEXML_Char, 0 if EOF is reached, or 1 if succeed. + */ + virtual int get (ACEXML_Char& ch); + + /** + * Read the next batch of ACEXML_Char strings + */ + virtual int read (ACEXML_Char *str, size_t len); + + /** + * Determine the encoding of the file. + */ + virtual int determine_encoding (void); + + + /** + * Peek the next ACEXML_Char in the CharStream. Return the + * character if success, -1 if EOF is reached. + */ + virtual int peek (void); + + /** + * Resets the file pointer to the beginning of the stream. + */ + virtual void rewind (void); + + /* + * Get the character encoding for a byte stream or URI. + */ + virtual const ACEXML_Char *getEncoding (void); + + /* + * Get the systemId for the underlying CharStream + */ + virtual const ACEXML_Char* getSystemId (void); + +protected: + + /** Read the next character as a normal character. Return -1 if EOF is + * reached, else return 0. + */ + virtual int getchar_i (char& ch); + + /** + * Peek @c offset bytes into the stream and return the character at @c + * offset. If EOF is reached, return -1. + */ + virtual int peekchar_i (off_t offset = 0); + +private: + +#if defined (ACE_USES_WCHAR) + /** + * Read the next character from the stream taking into account the + * encoding of the file. + */ + int get_i (ACEXML_Char& ch); + + /** + * Return the next character from the stream taking into account the + * encoding of the file. Subsequent call to get() returns this + * character. + */ + int peek_i (void); + +#endif /* ACE_USES_WCHAR */ + + ACEXML_Char* filename_; + ACEXML_Char* encoding_; + off_t size_; + ZZIP_FILE* infile_; + char buf_[80]; + int pos_; + int limit_; +}; + +#include "ace/post.h" + +#ifdef ACEXML_save_read +#define read ACEXML_save_read +#undef ACEXML_save_read +#endif + +#endif /* ACEXML_HAS_ZZIPLIB */ + +#endif /* _ACEXML_ZIPCHARSTREAM_H_ */ diff --git a/ACEXML/examples/Makefile b/ACEXML/examples/Makefile deleted file mode 100644 index a508ee1d096..00000000000 --- a/ACEXML/examples/Makefile +++ /dev/null @@ -1,17 +0,0 @@ -#---------------------------------------------------------------------------- -# $Id$ -# -# Makefile for the client programs that test the ACE network services -#---------------------------------------------------------------------------- - -DIRS = SAXPrint - -#---------------------------------------------------------------------------- -# Include macros and targets -#---------------------------------------------------------------------------- - -include $(ACE_ROOT)/include/makeinclude/wrapper_macros.GNU -include $(ACE_ROOT)/include/makeinclude/macros.GNU -include $(ACE_ROOT)/include/makeinclude/rules.common.GNU -include $(ACE_ROOT)/include/makeinclude/rules.nested.GNU -include $(ACE_ROOT)/include/makeinclude/rules.nolocal.GNU diff --git a/ACEXML/examples/SAXPrint/Makefile b/ACEXML/examples/SAXPrint/Makefile index 728d6d7f1f5..79a07ed6ca5 100644 --- a/ACEXML/examples/SAXPrint/Makefile +++ b/ACEXML/examples/SAXPrint/Makefile @@ -1,267 +1,14 @@ +# $Id$ #---------------------------------------------------------------------------- -# $Id$ -# -# Makefile for repeating token client application +# GNU ACE Workspace #---------------------------------------------------------------------------- -#---------------------------------------------------------------------------- -# Local macros -#---------------------------------------------------------------------------- - -LDLIBS = -lACEXML_Parser -lACEXML -FILES = Print_Handler \ - SAXPrint_Handler - -SRC = $(addsuffix .cpp,$(FILES)) -OBJ = $(LSRC:%.cpp=$(VDIR)%.o) - -BIN = main - -BUILD = $(VBIN) - -#---------------------------------------------------------------------------- -# Include macros and targets -#---------------------------------------------------------------------------- - -include $(ACE_ROOT)/include/makeinclude/wrapper_macros.GNU -include $(ACE_ROOT)/include/makeinclude/macros.GNU -include $(ACE_ROOT)/include/makeinclude/rules.common.GNU -include $(ACE_ROOT)/include/makeinclude/rules.nonested.GNU -include $(ACE_ROOT)/include/makeinclude/rules.bin.GNU -include $(ACE_ROOT)/include/makeinclude/rules.local.GNU - -#---------------------------------------------------------------------------- -# Local targets -#---------------------------------------------------------------------------- - -#---------------------------------------------------------------------------- -# Dependencies -#---------------------------------------------------------------------------- - -# IF YOU PUT ANYTHING HERE IT WILL GO AWAY -# DO NOT DELETE THIS LINE -- g++dep uses it. -# DO NOT PUT ANYTHING AFTER THIS LINE, IT WILL GO AWAY. - - -.obj/Print_Handler.o .obj/Print_Handler.so .shobj/Print_Handler.o .shobj/Print_Handler.so: Print_Handler.cpp Print_Handler.h \ - $(ACE_ROOT)/ACEXML/common/DefaultHandler.h \ - $(ACE_ROOT)/ace/pre.h \ - $(ACE_ROOT)/ACEXML/common/ACEXML_Export.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - $(ACE_ROOT)/ACEXML/common/ContentHandler.h \ - $(ACE_ROOT)/ACEXML/common/Env.h \ - $(ACE_ROOT)/ACEXML/common/XML_Macros.h \ - $(ACE_ROOT)/ace/Exception_Macros.h \ - $(ACE_ROOT)/ACEXML/common/Exception.h \ - $(ACE_ROOT)/ACEXML/common/XML_Types.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h \ - $(ACE_ROOT)/ace/Trace.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - $(ACE_ROOT)/ace/SString.i \ - $(ACE_ROOT)/ACEXML/common/Exception.i \ - $(ACE_ROOT)/ACEXML/common/Env.i \ - $(ACE_ROOT)/ACEXML/common/SAXExceptions.h \ - $(ACE_ROOT)/ACEXML/common/SAXExceptions.i \ - $(ACE_ROOT)/ACEXML/common/Locator.h \ - $(ACE_ROOT)/ACEXML/common/Attributes.h \ - $(ACE_ROOT)/ACEXML/common/DTDHandler.h \ - $(ACE_ROOT)/ACEXML/common/EntityResolver.h \ - $(ACE_ROOT)/ACEXML/common/InputSource.h \ - $(ACE_ROOT)/ACEXML/common/CharStream.h \ - $(ACE_ROOT)/ACEXML/common/ErrorHandler.h \ - $(ACE_ROOT)/ACEXML/common/DefaultHandler.i - -.obj/SAXPrint_Handler.o .obj/SAXPrint_Handler.so .shobj/SAXPrint_Handler.o .shobj/SAXPrint_Handler.so: SAXPrint_Handler.cpp SAXPrint_Handler.h \ - $(ACE_ROOT)/ACEXML/common/DefaultHandler.h \ - $(ACE_ROOT)/ace/pre.h \ - $(ACE_ROOT)/ACEXML/common/ACEXML_Export.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - $(ACE_ROOT)/ACEXML/common/ContentHandler.h \ - $(ACE_ROOT)/ACEXML/common/Env.h \ - $(ACE_ROOT)/ACEXML/common/XML_Macros.h \ - $(ACE_ROOT)/ace/Exception_Macros.h \ - $(ACE_ROOT)/ACEXML/common/Exception.h \ - $(ACE_ROOT)/ACEXML/common/XML_Types.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h \ - $(ACE_ROOT)/ace/Trace.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - $(ACE_ROOT)/ace/SString.i \ - $(ACE_ROOT)/ACEXML/common/Exception.i \ - $(ACE_ROOT)/ACEXML/common/Env.i \ - $(ACE_ROOT)/ACEXML/common/SAXExceptions.h \ - $(ACE_ROOT)/ACEXML/common/SAXExceptions.i \ - $(ACE_ROOT)/ACEXML/common/Locator.h \ - $(ACE_ROOT)/ACEXML/common/Attributes.h \ - $(ACE_ROOT)/ACEXML/common/DTDHandler.h \ - $(ACE_ROOT)/ACEXML/common/EntityResolver.h \ - $(ACE_ROOT)/ACEXML/common/InputSource.h \ - $(ACE_ROOT)/ACEXML/common/CharStream.h \ - $(ACE_ROOT)/ACEXML/common/ErrorHandler.h \ - $(ACE_ROOT)/ACEXML/common/DefaultHandler.i \ - SAXPrint_Handler.i +include $(ACE_ROOT)/include/makeinclude/macros.GNU +TARGETS_NESTED := $(TARGETS_NESTED:.nested=) -# IF YOU PUT ANYTHING HERE IT WILL GO AWAY +$(TARGETS_NESTED): +ifneq (Windows,$(findstring Windows,$(OS))) + @$(MAKE) -f Makefile.SAXPrint -C . $(@); +else + -@cmd /c "$(MAKE) -f Makefile.SAXPrint -C . $(@)" +endif diff --git a/ACEXML/examples/SAXPrint/Makefile.SAXPrint b/ACEXML/examples/SAXPrint/Makefile.SAXPrint new file mode 100644 index 00000000000..0ac857c9f99 --- /dev/null +++ b/ACEXML/examples/SAXPrint/Makefile.SAXPrint @@ -0,0 +1,57 @@ +#---------------------------------------------------------------------------- +# GNU Makefile +#---------------------------------------------------------------------------- +MAKEFILE = Makefile.SAXPrint +DEPENDENCY_FILE = .depend.Makefile.SAXPrint +BIN_UNCHECKED = SAXPrint + + + +FILES = \ + main \ + SAXPrint_Handler \ + Print_Handler +#---------------------------------------------------------------------------- +# Include macros and targets +#---------------------------------------------------------------------------- + +include $(ACE_ROOT)/include/makeinclude/wrapper_macros.GNU + +BIN = $(BIN_UNCHECKED) + +OBJS = $(addsuffix .o, $(notdir $(FILES))) +SRC = $(addsuffix .cpp, $(FILES)) +ACELIB = -lACE + +include $(ACE_ROOT)/include/makeinclude/macros.GNU +include $(ACE_ROOT)/include/makeinclude/rules.common.GNU +include $(ACE_ROOT)/include/makeinclude/rules.nonested.GNU +include $(ACE_ROOT)/include/makeinclude/rules.local.GNU + +CPPFLAGS += -I../../.. + + +ifeq ($(static_libs),1) + ifneq ($(LIB),) + CPPFLAGS += -DACE_AS_STATIC_LIBS + endif +endif + + +LDFLAGS += -L../../../ACEXML/common -L../../../ACEXML/parser/parser -L../../../ace + + + +LDLIBS = -lACEXML_Parser -lACEXML +#---------------------------------------------------------------------------- +# Local targets +#---------------------------------------------------------------------------- + +$(BIN): $(addprefix $(VDIR), $(OBJS)) + $(LINK.cc) $(LDFLAGS) $(CC_OUTPUT_FLAG) $@ $^ $(VLDLIBS) $(POSTLINK) + +realclean: clean +ifneq ($(GENERATED_DIRTY),) + -$(RM) -r $(GENERATED_DIRTY) +endif + diff --git a/ACEXML/examples/SAXPrint/Makefile.SAXPrint.bor b/ACEXML/examples/SAXPrint/Makefile.SAXPrint.bor new file mode 100644 index 00000000000..9b243343eaa --- /dev/null +++ b/ACEXML/examples/SAXPrint/Makefile.SAXPrint.bor @@ -0,0 +1,55 @@ +# Makefile for building the SAXPrint exe with Borland C++ Builder + +NAME = SAXPrint + +NAME = SAXPrint + + +OBJFILES = \ + $(OBJDIR)\Print_Handler.obj \ + $(OBJDIR)\SAXPrint_Handler.obj \ + $(OBJDIR)\main.obj + +EXTERNAL_LIBS = \ + \ + +LFLAGS = \ + -j..\..\..\ACEXML\common\$(CONFIG_SUBDIR) -j..\..\..\ACEXML\common \ + -L..\..\..\ACEXML\common\$(CONFIG_SUBDIR) -L..\..\..\ACEXML\common \ + -j..\..\..\ACEXML\parser\parser\$(CONFIG_SUBDIR) -j..\..\..\ACEXML\parser\parser \ + -L..\..\..\ACEXML\parser\parser\$(CONFIG_SUBDIR) -L..\..\..\ACEXML\parser\parser \ + -j..\..\..\ace\$(CONFIG_SUBDIR) -j..\..\..\ace \ + -L..\..\..\ace\$(CONFIG_SUBDIR) -L..\..\..\ace \ + -j$(CORE_BINDIR) \ + -L$(CORE_BINDIR) + +LIBFILES = \ + ACEXML_Parser$(LIB_DECORATOR).lib \ + ACEXML$(LIB_DECORATOR).lib \ + ACE$(LIB_DECORATOR).lib \ + $(EXTERNAL_LIBS) + + + +!ifdef STATIC +LIB_FLAGS = -DACE_AS_STATIC_LIBS +DLL_FLAGS = +!else +LIB_FLAGS = +DLL_FLAGS = +!endif + +CFLAGS = \ + -I..\..\.. \ + $(LIB_FLAGS) \ + $(DLL_FLAGS) + +CPPDIR = . + +INCLUDES = \ + Print_Handler.h \ + SAXPrint_Handler.h \ + Print_Handler.i \ + SAXPrint_Handler.i + +!include <$(ACE_ROOT)\include\makeinclude\build_exe.bor> diff --git a/ACEXML/examples/SAXPrint/Makefile.bor b/ACEXML/examples/SAXPrint/Makefile.bor index 89c1f051772..2db22658bac 100644 --- a/ACEXML/examples/SAXPrint/Makefile.bor +++ b/ACEXML/examples/SAXPrint/Makefile.bor @@ -1,25 +1,20 @@ -# -# $Id$ -# Makefile for building the SAXPrint example -# +#---------------------------------------------------------------------------- +# Borland Workspace +#---------------------------------------------------------------------------- -NAME = SAXPrint +!include <$(ACE_ROOT)\include\makeinclude\make_flags.bor> -OBJFILES = \ - $(OBJDIR)\Print_Handler.obj \ - $(OBJDIR)\SAXPrint_Handler.obj \ - $(OBJDIR)\main.obj +all: + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.SAXPrint.bor all -CFLAGS = \ - $(ACE_CFLAGS) \ - $(ACE_XML_CFLAGS) \ - $(ACE_XML_PARSER_CFLAGS) +clean: + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.SAXPrint.bor clean -CPPDIR = . +realclean: + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.SAXPrint.bor realclean -LIBFILES = \ - $(ACE_LIB) \ - $(ACE_XML_LIB) \ - $(ACE_XML_PARSER_LIB) +install: + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.SAXPrint.bor install -!include <$(ACE_ROOT)\include\makeinclude\build_exe.bor> +regenerate: + D:\Perl\bin\perl.exe D:\ACE_wrappers\bin\mwc.pl -type borland -recurse diff --git a/ACEXML/examples/SAXPrint/Print_Handler.cpp b/ACEXML/examples/SAXPrint/Print_Handler.cpp index 19cfb44ba8d..1dca52c8a37 100644 --- a/ACEXML/examples/SAXPrint/Print_Handler.cpp +++ b/ACEXML/examples/SAXPrint/Print_Handler.cpp @@ -22,19 +22,19 @@ ACEXML_Print_Handler::~ACEXML_Print_Handler (void) void ACEXML_Print_Handler::characters (const ACEXML_Char *cdata, int start, - int end ACEXML_ENV_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) + int length ACEXML_ENV_ARG_DECL_NOT_USED) + ACE_THROW_SPEC ((ACEXML_SAXException)) { ACE_DEBUG ((LM_DEBUG, ACE_TEXT ("* Event characters () ** start: %d end: %d ***************\n%s\n- End event characters () ---------------\n"), - start, end, cdata)); + start, length, cdata)); } void ACEXML_Print_Handler::endDocument (ACEXML_ENV_SINGLE_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) + ACE_THROW_SPEC ((ACEXML_SAXException)) { @@ -47,7 +47,7 @@ ACEXML_Print_Handler::endElement (const ACEXML_Char *uri, const ACEXML_Char *name, const ACEXML_Char *qName ACEXML_ENV_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) + ACE_THROW_SPEC ((ACEXML_SAXException)) { @@ -59,7 +59,7 @@ ACEXML_Print_Handler::endElement (const ACEXML_Char *uri, void ACEXML_Print_Handler::endPrefixMapping (const ACEXML_Char *prefix ACEXML_ENV_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) + ACE_THROW_SPEC ((ACEXML_SAXException)) { @@ -73,19 +73,17 @@ ACEXML_Print_Handler::ignorableWhitespace (const ACEXML_Char *, int, int ACEXML_ENV_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) + ACE_THROW_SPEC ((ACEXML_SAXException)) { - - - ACE_DEBUG ((LM_DEBUG, - ACE_TEXT ("* Event ignorableWhitespace () ***************\n"))); + // ACE_DEBUG ((LM_DEBUG, + // ACE_TEXT ("* Event ignorableWhitespace () ***************\n"))); } void ACEXML_Print_Handler::processingInstruction (const ACEXML_Char *target, const ACEXML_Char *data ACEXML_ENV_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) + ACE_THROW_SPEC ((ACEXML_SAXException)) { @@ -99,14 +97,13 @@ ACEXML_Print_Handler::setDocumentLocator (ACEXML_Locator * locator) { this->locator_ = locator; - ACE_DEBUG ((LM_DEBUG, - ACE_TEXT ("* Event setDocumentLocator () ***************\n"))); + // ACE_DEBUG ((LM_DEBUG, ACE_TEXT ("* Event setDocumentLocator () ***************\n"))); } void ACEXML_Print_Handler::skippedEntity (const ACEXML_Char *name ACEXML_ENV_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) + ACE_THROW_SPEC ((ACEXML_SAXException)) { @@ -117,7 +114,7 @@ ACEXML_Print_Handler::skippedEntity (const ACEXML_Char *name void ACEXML_Print_Handler::startDocument (ACEXML_ENV_SINGLE_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) + ACE_THROW_SPEC ((ACEXML_SAXException)) { @@ -131,7 +128,7 @@ ACEXML_Print_Handler::startElement (const ACEXML_Char *uri, const ACEXML_Char *qName, ACEXML_Attributes *alist ACEXML_ENV_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) + ACE_THROW_SPEC ((ACEXML_SAXException)) { @@ -151,7 +148,7 @@ ACEXML_Print_Handler::startElement (const ACEXML_Char *uri, void ACEXML_Print_Handler::startPrefixMapping (const ACEXML_Char * prefix, const ACEXML_Char * uri ACEXML_ENV_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) + ACE_THROW_SPEC ((ACEXML_SAXException)) { ACE_DEBUG ((LM_DEBUG, ACE_TEXT ("* Event startPrefixMapping () ***************\n"))); @@ -165,7 +162,7 @@ void ACEXML_Print_Handler::notationDecl (const ACEXML_Char *name, const ACEXML_Char *publicID, const ACEXML_Char *systemID ACEXML_ENV_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) + ACE_THROW_SPEC ((ACEXML_SAXException)) { ACE_DEBUG ((LM_DEBUG, ACE_TEXT ("* Event notationDecl: (%s) "), @@ -190,7 +187,7 @@ ACEXML_Print_Handler::unparsedEntityDecl (const ACEXML_Char *name, const ACEXML_Char *publicID, const ACEXML_Char *systemID, const ACEXML_Char *notationName ACEXML_ENV_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) + ACE_THROW_SPEC ((ACEXML_SAXException)) { ACE_DEBUG ((LM_DEBUG, ACE_TEXT ("* Unparsed Entity: %s"), @@ -215,7 +212,7 @@ ACEXML_Print_Handler::unparsedEntityDecl (const ACEXML_Char *name, ACEXML_InputSource * ACEXML_Print_Handler::resolveEntity (const ACEXML_Char *, const ACEXML_Char * ACEXML_ENV_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) + ACE_THROW_SPEC ((ACEXML_SAXException)) { // No-op. return 0; @@ -223,15 +220,15 @@ ACEXML_Print_Handler::resolveEntity (const ACEXML_Char *, // Methods inherit from ACEXML_ErrorHandler. - /* - * Receive notification of a recoverable error. - */ +/* + * Receive notification of a recoverable error. + */ void ACEXML_Print_Handler::error (ACEXML_SAXParseException & ex ACEXML_ENV_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) + ACE_THROW_SPEC ((ACEXML_SAXException)) { - - ACE_DEBUG ((LM_DEBUG, "%s:%d:%d ", this->fileName_, + ACE_DEBUG ((LM_DEBUG, "%s: line: %d col: %d ", + (this->locator_->getSystemId() == 0 ? this->fileName_ : this->locator_->getSystemId()), this->locator_->getLineNumber(), this->locator_->getColumnNumber())); ex.print(); @@ -239,18 +236,23 @@ ACEXML_Print_Handler::error (ACEXML_SAXParseException & ex ACEXML_ENV_ARG_DECL_N void ACEXML_Print_Handler::fatalError (ACEXML_SAXParseException& ex ACEXML_ENV_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) + ACE_THROW_SPEC ((ACEXML_SAXException)) { - - ACE_DEBUG ((LM_DEBUG, "%s:%d:%d ", this->fileName_, + ACE_DEBUG ((LM_DEBUG, "%s: line: %d col: %d ", + (this->locator_->getSystemId() == 0 ? this->fileName_ : this->locator_->getSystemId()), this->locator_->getLineNumber(), this->locator_->getColumnNumber())); ex.print(); + } void -ACEXML_Print_Handler::warning (ACEXML_SAXParseException & ACEXML_ENV_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) +ACEXML_Print_Handler::warning (ACEXML_SAXParseException & ex ACEXML_ENV_ARG_DECL_NOT_USED) + ACE_THROW_SPEC ((ACEXML_SAXException)) { - // No-op. + ACE_DEBUG ((LM_DEBUG, "%s: line: %d col: %d ", + (this->locator_->getSystemId() == 0 ? this->fileName_ : this->locator_->getSystemId()), + this->locator_->getLineNumber(), + this->locator_->getColumnNumber())); + ex.print(); } diff --git a/ACEXML/examples/SAXPrint/SAXPrint.dsp b/ACEXML/examples/SAXPrint/SAXPrint.dsp index 2d9a6cc4a98..7c86c6368d2 100644 --- a/ACEXML/examples/SAXPrint/SAXPrint.dsp +++ b/ACEXML/examples/SAXPrint/SAXPrint.dsp @@ -1,25 +1,26 @@ -# Microsoft Developer Studio Project File - Name="SAXPrint" - Package Owner=<4>
+# Microsoft Developer Studio Project File - Name="SAXPrint EXE" - Package Owner=<4>
# Microsoft Developer Studio Generated Build File, Format Version 6.00
# ** DO NOT EDIT **
# TARGTYPE "Win32 (x86) Console Application" 0x0103
-CFG=SAXPrint - Win32 Debug
+CFG=SAXPrint EXE - Win32 Debug
!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
+!MESSAGE run the tool that generated this project file and specify the
+!MESSAGE nmake output type. You can then use the following command:
+!MESSAGE
!MESSAGE NMAKE /f "SAXPrint.mak".
-!MESSAGE
+!MESSAGE
!MESSAGE You can specify a configuration when running NMAKE
!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "SAXPrint.mak" CFG="SAXPrint - Win32 Debug"
-!MESSAGE
+!MESSAGE
+!MESSAGE NMAKE /f "SAXPrint.mak" CFG="SAXPrint EXE - Win32 Debug"
+!MESSAGE
!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "SAXPrint - Win32 Release" (based on "Win32 (x86) Console Application")
-!MESSAGE "SAXPrint - Win32 Debug" (based on "Win32 (x86) Console Application")
-!MESSAGE
+!MESSAGE
+!MESSAGE "SAXPrint EXE - Win32 Release" (based on "Win32 (x86) Console Application")
+!MESSAGE "SAXPrint EXE - Win32 Debug" (based on "Win32 (x86) Console Application")
+!MESSAGE
# Begin Project
# PROP AllowPerConfigDependencies 0
@@ -28,63 +29,45 @@ CFG=SAXPrint - Win32 Debug CPP=cl.exe
RSC=rc.exe
-!IF "$(CFG)" == "SAXPrint - Win32 Release"
+!IF "$(CFG)" == "SAXPrint EXE - Win32 Release"
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release"
-# PROP BASE Intermediate_Dir "Release"
-# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 0
-# PROP Output_Dir ""
-# PROP Intermediate_Dir "Release"
-# PROP Ignore_Export_Lib 0
+# PROP Output_Dir "Release"
+# PROP Intermediate_Dir "Release\SAXPrint"
# PROP Target_Dir ""
-# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "../../.." /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
-# ADD BASE RSC /l 0x409 /d "NDEBUG"
-# ADD RSC /l 0x409 /d "NDEBUG"
+# ADD CPP /nologo /W3 /GX /O2 /MD /GR /I "..\..\.." /D NDEBUG=1 /D WIN32=1 /D _CONSOLE=1 /FD /c
+# SUBTRACT CPP /YX
+# ADD RSC /l 0x409 /d NDEBUG=1 /i "..\..\.."
BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
+# ADD BSC32 /nologo
LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386
-# ADD LINK32 ace.lib ACEXML.lib ACEXML_Parser.lib /nologo /subsystem:console /machine:I386 /libpath:"..\..\..\ace" /libpath:"..\..\Common" /libpath:"..\..\parser\parser"
+# ADD LINK32 advapi32.lib user32.lib /INCREMENTAL:NO ACEXML_Parser.lib ACEXML.lib ACE.lib /libpath:"..\..\..\ACEXML\common" /libpath:"..\..\..\ACEXML\parser\parser" /libpath:"..\..\..\ace" /nologo /version:5.3.1 /subsystem:console /pdb:"Release\SAXPrint.pdb" /machine:I386 /out:"Release\SAXPrint.exe"
-!ELSEIF "$(CFG)" == "SAXPrint - Win32 Debug"
+!ELSEIF "$(CFG)" == "SAXPrint EXE - Win32 Debug"
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug"
-# PROP BASE Intermediate_Dir "Debug"
-# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 1
-# PROP Output_Dir ""
-# PROP Intermediate_Dir "Debug"
-# PROP Ignore_Export_Lib 0
+# PROP Output_Dir "."
+# PROP Intermediate_Dir "Debug\SAXPrint"
# PROP Target_Dir ""
-# ADD BASE CPP /nologo /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /Zi /Od /I "../../.." /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
-# ADD BASE RSC /l 0x409 /d "_DEBUG"
-# ADD RSC /l 0x409 /d "_DEBUG"
+# ADD CPP /nologo /W3 /Gm /GX /Zi /Od /MDd /GR /Gy /I "..\..\.." /D _DEBUG=1 /D WIN32=1 /D _CONSOLE=1 /FD /c
+# SUBTRACT CPP /YX
+# ADD RSC /l 0x409 /d _DEBUG=1 /i "..\..\.."
BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
+# ADD BSC32 /nologo
LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 aced.lib ACEXMLd.lib ACEXML_Parserd.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept /libpath:"..\..\..\ace" /libpath:"..\..\Common" /libpath:"..\..\parser\parser"
+# ADD LINK32 advapi32.lib user32.lib /INCREMENTAL:NO ACEXML_Parserd.lib ACEXMLd.lib ACEd.lib /libpath:"..\..\..\ACEXML\common" /libpath:"..\..\..\ACEXML\parser\parser" /libpath:"..\..\..\ace" /nologo /version:5.3.1 /subsystem:console /pdb:".\SAXPrint.pdb" /debug /machine:I386 /out:".\SAXPrint.exe"
-!ENDIF
+!ENDIF
# Begin Target
-# Name "SAXPrint - Win32 Release"
-# Name "SAXPrint - Win32 Debug"
+# Name "SAXPrint EXE - Win32 Release"
+# Name "SAXPrint EXE - Win32 Debug"
# Begin Group "Source Files"
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
+# PROP Default_Filter "cpp;cxx;c"
# Begin Source File
SOURCE=.\main.cpp
@@ -100,7 +83,7 @@ SOURCE=.\SAXPrint_Handler.cpp # End Group
# Begin Group "Header Files"
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
+# PROP Default_Filter "h;hpp;hxx;hh"
# Begin Source File
SOURCE=.\Print_Handler.h
@@ -110,13 +93,9 @@ SOURCE=.\Print_Handler.h SOURCE=.\SAXPrint_Handler.h
# End Source File
# End Group
-# Begin Group "Resource Files"
-
-# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
-# End Group
# Begin Group "Inline Files"
-# PROP Default_Filter "i"
+# PROP Default_Filter "i;inl"
# Begin Source File
SOURCE=.\Print_Handler.i
diff --git a/ACEXML/examples/SAXPrint/SAXPrint.mpc b/ACEXML/examples/SAXPrint/SAXPrint.mpc index fb64bc80fcd..0dce21006be 100644 --- a/ACEXML/examples/SAXPrint/SAXPrint.mpc +++ b/ACEXML/examples/SAXPrint/SAXPrint.mpc @@ -1,2 +1,3 @@ project(SAXPrint): aceexe, acexml { + exename = SAXPrint } diff --git a/ACEXML/examples/SAXPrint/SAXPrint_Handler.cpp b/ACEXML/examples/SAXPrint/SAXPrint_Handler.cpp index 66d96dca47b..dd09a189647 100644 --- a/ACEXML/examples/SAXPrint/SAXPrint_Handler.cpp +++ b/ACEXML/examples/SAXPrint/SAXPrint_Handler.cpp @@ -22,12 +22,12 @@ ACEXML_SAXPrint_Handler::~ACEXML_SAXPrint_Handler (void) void ACEXML_SAXPrint_Handler::characters (const ACEXML_Char *cdata, int start, - int end ACEXML_ENV_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) + int length ACEXML_ENV_ARG_DECL_NOT_USED) + ACE_THROW_SPEC ((ACEXML_SAXException)) { ACE_UNUSED_ARG (start); - ACE_UNUSED_ARG (end); + ACE_UNUSED_ARG (length); ACE_DEBUG ((LM_DEBUG, ACE_TEXT ("%s"), cdata)); @@ -35,7 +35,7 @@ ACEXML_SAXPrint_Handler::characters (const ACEXML_Char *cdata, void ACEXML_SAXPrint_Handler::endDocument (ACEXML_ENV_SINGLE_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) + ACE_THROW_SPEC ((ACEXML_SAXException)) { @@ -47,7 +47,7 @@ ACEXML_SAXPrint_Handler::endElement (const ACEXML_Char *, const ACEXML_Char *, const ACEXML_Char *qName ACEXML_ENV_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) + ACE_THROW_SPEC ((ACEXML_SAXException)) { @@ -61,32 +61,31 @@ ACEXML_SAXPrint_Handler::endElement (const ACEXML_Char *, void ACEXML_SAXPrint_Handler::endPrefixMapping (const ACEXML_Char *prefix ACEXML_ENV_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) + ACE_THROW_SPEC ((ACEXML_SAXException)) { - - - ACE_DEBUG ((LM_DEBUG, - ACE_TEXT ("* Event endPrefixMapping (%s) ***************\n"), - prefix)); +// ACE_DEBUG ((LM_DEBUG, +// ACE_TEXT ("* Event endPrefixMapping (%s) ***************\n"), +// prefix)); } void -ACEXML_SAXPrint_Handler::ignorableWhitespace (const ACEXML_Char *, +ACEXML_SAXPrint_Handler::ignorableWhitespace (const ACEXML_Char * cdata, int, int ACEXML_ENV_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) + ACE_THROW_SPEC ((ACEXML_SAXException)) { - - ACE_DEBUG ((LM_DEBUG, - ACE_TEXT ("* Event ignorableWhitespace () ***************\n"))); + ACE_TEXT ("%s"), + cdata)); +// ACE_DEBUG ((LM_DEBUG, + // ACE_TEXT ("* Event ignorableWhitespace () ***************\n"))); } void ACEXML_SAXPrint_Handler::processingInstruction (const ACEXML_Char *target, const ACEXML_Char *data ACEXML_ENV_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) + ACE_THROW_SPEC ((ACEXML_SAXException)) { @@ -101,14 +100,13 @@ ACEXML_SAXPrint_Handler::setDocumentLocator (ACEXML_Locator * locator) { this->locator_ = locator; - ACE_DEBUG ((LM_DEBUG, - ACE_TEXT ("* Event setDocumentLocator () ***************\n"))); + //ACE_DEBUG ((LM_DEBUG, ACE_TEXT ("* Event setDocumentLocator () ***************\n"))); } void ACEXML_SAXPrint_Handler::skippedEntity (const ACEXML_Char *name ACEXML_ENV_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) + ACE_THROW_SPEC ((ACEXML_SAXException)) { @@ -119,7 +117,7 @@ ACEXML_SAXPrint_Handler::skippedEntity (const ACEXML_Char *name void ACEXML_SAXPrint_Handler::startDocument (ACEXML_ENV_SINGLE_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) + ACE_THROW_SPEC ((ACEXML_SAXException)) { @@ -133,7 +131,7 @@ ACEXML_SAXPrint_Handler::startElement (const ACEXML_Char *, const ACEXML_Char *qName, ACEXML_Attributes *alist ACEXML_ENV_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) + ACE_THROW_SPEC ((ACEXML_SAXException)) { @@ -155,12 +153,12 @@ ACEXML_SAXPrint_Handler::startElement (const ACEXML_Char *, void ACEXML_SAXPrint_Handler::startPrefixMapping (const ACEXML_Char * prefix, const ACEXML_Char * uri ACEXML_ENV_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) + ACE_THROW_SPEC ((ACEXML_SAXException)) { - ACE_DEBUG ((LM_DEBUG, - ACE_TEXT ("* Event startPrefixMapping () ***************\n"))); - ACE_DEBUG ((LM_DEBUG, - ACE_TEXT ("Prefix = %s, URI = %s\n"), prefix, uri)); +// ACE_DEBUG ((LM_DEBUG, +// ACE_TEXT ("* Event startPrefixMapping () ***************\n"))); +// ACE_DEBUG ((LM_DEBUG, +// ACE_TEXT ("Prefix = %s, URI = %s\n"), prefix, uri)); } @@ -170,7 +168,7 @@ void ACEXML_SAXPrint_Handler::notationDecl (const ACEXML_Char *, const ACEXML_Char *, const ACEXML_Char * ACEXML_ENV_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) + ACE_THROW_SPEC ((ACEXML_SAXException)) { // No-op. } @@ -180,7 +178,7 @@ ACEXML_SAXPrint_Handler::unparsedEntityDecl (const ACEXML_Char *, const ACEXML_Char *, const ACEXML_Char *, const ACEXML_Char * ACEXML_ENV_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) + ACE_THROW_SPEC ((ACEXML_SAXException)) { // No-op. } @@ -190,7 +188,7 @@ ACEXML_SAXPrint_Handler::unparsedEntityDecl (const ACEXML_Char *, ACEXML_InputSource * ACEXML_SAXPrint_Handler::resolveEntity (const ACEXML_Char *, const ACEXML_Char * ACEXML_ENV_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) + ACE_THROW_SPEC ((ACEXML_SAXException)) { // No-op. return 0; @@ -198,15 +196,16 @@ ACEXML_SAXPrint_Handler::resolveEntity (const ACEXML_Char *, // Methods inherited from ACEXML_ErrorHandler. - /* - * Receive notification of a recoverable error. - */ +/* + * Receive notification of a recoverable error. + */ void ACEXML_SAXPrint_Handler::error (ACEXML_SAXParseException & ex ACEXML_ENV_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) + ACE_THROW_SPEC ((ACEXML_SAXException)) { - ACE_DEBUG ((LM_DEBUG, "%s: line :%d col: %d ", this->fileName_, + ACE_DEBUG ((LM_DEBUG, "%s: line: %d col: %d ", + (this->locator_->getSystemId() == 0 ? this->fileName_ : this->locator_->getSystemId()), this->locator_->getLineNumber(), this->locator_->getColumnNumber())); ex.print(); @@ -215,9 +214,10 @@ ACEXML_SAXPrint_Handler::error (ACEXML_SAXParseException & ex void ACEXML_SAXPrint_Handler::fatalError (ACEXML_SAXParseException & ex ACEXML_ENV_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) + ACE_THROW_SPEC ((ACEXML_SAXException)) { - ACE_DEBUG ((LM_DEBUG, "%s: line :%d col: %d ", this->fileName_, + ACE_DEBUG ((LM_DEBUG, "%s: line: %d col: %d ", + (this->locator_->getSystemId() == 0 ? this->fileName_ : this->locator_->getSystemId()), this->locator_->getLineNumber(), this->locator_->getColumnNumber())); ex.print(); @@ -226,9 +226,10 @@ ACEXML_SAXPrint_Handler::fatalError (ACEXML_SAXParseException & ex void ACEXML_SAXPrint_Handler::warning (ACEXML_SAXParseException & ex ACEXML_ENV_ARG_DECL_NOT_USED) - ACE_THROW_SPEC ((ACEXML_SAXException)) + ACE_THROW_SPEC ((ACEXML_SAXException)) { - ACE_DEBUG ((LM_DEBUG, "%s: line :%d col: %d ", this->fileName_, + ACE_DEBUG ((LM_DEBUG, "%s: line: %d col: %d ", + (this->locator_->getSystemId() == 0 ? this->fileName_ : this->locator_->getSystemId()), this->locator_->getLineNumber(), this->locator_->getColumnNumber())); ex.print(); diff --git a/ACEXML/examples/SAXPrint/main.cpp b/ACEXML/examples/SAXPrint/main.cpp index 64ce0125fe4..1b6cc2932fa 100644 --- a/ACEXML/examples/SAXPrint/main.cpp +++ b/ACEXML/examples/SAXPrint/main.cpp @@ -3,24 +3,26 @@ #include "ACEXML/common/FileCharStream.h" #include "ACEXML/common/HttpCharStream.h" #include "ACEXML/common/StrCharStream.h" +#include "ACEXML/common/ZipCharStream.h" #include "ACEXML/parser/parser/Parser.h" #include "Print_Handler.h" #include "SAXPrint_Handler.h" #include "ace/Get_Opt.h" #include "ace/Auto_Ptr.h" +#include "ace/Log_Msg.h" static const ACEXML_Char *test_string = -ACE_TEXT ("<?xml version='1.0'?> <ACE_Svc_Conf> <static id=\"ACE_Service_Manager\" params='-d -p 4911'/> <dynamic id=\"Test_Task\" type=\"service_object\"> A & <initializer path=\"CCM_App\" init='_make_Test_Task' params='-p 3000'/> </dynamic> </ACE_Svc_Conf>"); +ACE_TEXT ("<?xml version='1.0'?> <ACE_Svc_Conf> <static id=\"ACE_Service_Manager\" params='-d -p 4911'/> <dynamic id=\"Test_Task\" type=\"service_object\"> A " <initializer path=\"CCM_App\" init='_make_Test_Task' params='-p 3000'/> </dynamic> </ACE_Svc_Conf>"); static void usage (const ACE_TCHAR* program) { ACE_ERROR ((LM_ERROR, - ACE_TEXT ("Usage: %s [-sl] [-f <filename> | -u <url>]\n") + ACE_TEXT ("Usage: %s [-sl] [-f <filename> | -u <url> | -z <ZIP Archive>]\n") ACE_TEXT (" -s: Use SAXPrint_Handler (Default is Print_Handler)\n") ACE_TEXT (" -l: Parse the internal strings (test the StrCharStream class)\n") ACE_TEXT (" -f: Specify the filename when -l is not specified\n") - ACE_TEXT (" -n: Use the \"Simple\" parsing feature\n") + ACE_TEXT (" -z: Specify that the file is inside a ZIP archive\n") ACE_TEXT (" -u: URL specifying the path to the file\n"), program)); } @@ -31,34 +33,41 @@ ACE_TMAIN (int argc, ACE_TCHAR *argv[]) ACEXML_Char* filename = 0; int sax = 0; // Use SAXPrint handler or not. int str = 0; - int simple = 0; + int zip = 0; ACEXML_Char* url = 0; - ACE_Get_Opt get_opt (argc, argv, ACE_TEXT ("snf:lu:")); + ACE_Get_Opt get_opt (argc, argv, ACE_TEXT ("sf:lu:z")); int c; while ((c = get_opt ()) != EOF) { switch (c) { - case 's': - sax = 1; - break; - case 'l': - str = 1; - break; - case 'f': - filename = get_opt.opt_arg (); - break; - case 'n': - simple = 1; - break; - case 'u': - url = get_opt.opt_arg(); - break; - default: - usage(argv[0]); - return -1; + case 's': + sax = 1; + break; + case 'l': + str = 1; + break; + case 'f': + filename = get_opt.opt_arg (); + break; + case 'u': + url = get_opt.opt_arg(); + break; + case 'z': + zip = 1; +#ifndef ACEXML_HAS_ZZIPLIB + ACE_ERROR ((LM_ERROR, ACE_TEXT ("ZZIPLIB support has not been") + ACE_TEXT (" compiled in. Refer to ") + ACE_TEXT ("$ACE_ROOT/ACEXML/README for more ") + ACE_TEXT ("information. \n"))); + return -1; +#endif /* ACEXML_HAS_ZZIPLIB */ + break; + default: + usage(argv[0]); + return -1; } } @@ -68,75 +77,90 @@ ACE_TMAIN (int argc, ACE_TCHAR *argv[]) } ACEXML_DefaultHandler *handler = 0; - auto_ptr<ACEXML_DefaultHandler> cleanup_handler (handler); ACEXML_CharStream *stm = 0; ACEXML_FileCharStream *fstm = 0; ACEXML_HttpCharStream *ustm = 0; - if (filename != 0) - { - ACE_NEW_RETURN (fstm, - ACEXML_FileCharStream (), - -1); - - if (fstm->open (filename) != 0) - ACE_ERROR_RETURN ((LM_ERROR, - ACE_TEXT ("Failed to open XML file: %s\n"), - filename), - -1); - stm = fstm; - } - else if (url != 0) - { + ACEXML_StrCharStream* sstm = 0; +#ifdef ACEXML_HAS_ZZIPLIB + ACEXML_ZipCharStream* zstm = 0; +#endif /* ACEXML_HAS_ZZIPLIB */ + if (filename != 0) + { +#ifdef ACEXML_HAS_ZZIPLIB + if (zip) + { + ACE_NEW_RETURN (zstm, ACEXML_ZipCharStream(), -1); + if (zstm->open (filename) != 0) + ACE_ERROR_RETURN ((LM_ERROR, + ACE_TEXT ("Failed to open XML file: %s\n"), + filename), + -1); + stm = zstm; + } + else + { +#endif /* ACEXML_HAS_ZZIPLIB */ + ACE_NEW_RETURN (fstm, ACEXML_FileCharStream (), -1); + if (fstm->open (filename) != 0) + ACE_ERROR_RETURN ((LM_ERROR, + ACE_TEXT ("Failed to open XML file: %s\n"), + filename), + -1); + stm = fstm; +#ifdef ACEXML_HAS_ZZIPLIB + } +#endif /* ACEXML_HAS_ZZIPLIB */ + } + else if (url != 0) + { - ACE_NEW_RETURN (ustm, - ACEXML_HttpCharStream (), - -1); - if (ustm->open (url) != 0) - ACE_ERROR_RETURN ((LM_ERROR, - ACE_TEXT ("Failed to open URL : %s\n"), - url), - -1); - stm = ustm; - } - else { - ACE_NEW_RETURN (stm, - ACEXML_StrCharStream (test_string), - -1); - } + ACE_NEW_RETURN (ustm, ACEXML_HttpCharStream (), -1); + if (ustm->open (url) != 0) + ACE_ERROR_RETURN ((LM_ERROR, + ACE_TEXT ("Failed to open URL : %s\n"), + url), + -1); + stm = ustm; + } + else + { + ACE_NEW_RETURN (sstm, ACEXML_StrCharStream, -1); + if (sstm->open (test_string, ACE_TEXT ("test_string")) < 0) + ACE_ERROR_RETURN ((LM_ERROR, + ACE_TEXT ("Failed to open string : %s\n"), + test_string), + -1); + stm = sstm; + } ACEXML_Char* name = (filename == 0) ? url : filename; - if (sax == 0) - ACE_NEW_RETURN (handler, + if (sax == 0) + ACE_NEW_RETURN (handler, ACEXML_Print_Handler (name), - -1); - else - ACE_NEW_RETURN (handler, + -1); + else + ACE_NEW_RETURN (handler, ACEXML_SAXPrint_Handler (name), - -1); - - ACEXML_TRY_NEW_ENV - { - ACEXML_Parser parser; - if (simple != 0) - { - parser.setFeature (ACE_TEXT ("Simple"), 1 ACEXML_ENV_ARG_PARAMETER); - ACEXML_TRY_CHECK; - } - ACEXML_InputSource input(stm); + -1); + auto_ptr<ACEXML_DefaultHandler> cleanup_handler (handler); - parser.setContentHandler (handler); - parser.setDTDHandler (handler); - parser.setErrorHandler (handler); - parser.setEntityResolver (handler); + ACEXML_Parser parser; + ACEXML_InputSource input (stm); - parser.parse (&input ACEXML_ENV_ARG_PARAMETER); - ACEXML_TRY_CHECK; - } + parser.setContentHandler (handler); + parser.setDTDHandler (handler); + parser.setErrorHandler (handler); + parser.setEntityResolver (handler); + ACEXML_TRY_NEW_ENV + { + parser.parse (&input ACEXML_ENV_ARG_PARAMETER); + ACEXML_TRY_CHECK; + } ACEXML_CATCH (ACEXML_SAXException, ex) { - ACE_UNUSED_ARG (ex); + ex.print(); ACE_DEBUG ((LM_ERROR, ACE_TEXT ("Exception occurred. Exiting...\n"))); - } + } ACEXML_ENDTRY; return 0; } diff --git a/ACEXML/examples/SAXPrint/namespaces.xml b/ACEXML/examples/SAXPrint/namespaces.xml new file mode 100644 index 00000000000..f2418848929 --- /dev/null +++ b/ACEXML/examples/SAXPrint/namespaces.xml @@ -0,0 +1,95 @@ +<?xml version="1.0" encoding="iso8859-1"?> + +<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:sy="http://purl.org/rss/1.0/modules/syndication/" xmlns:admin="http://webns.net/mvcb/" xmlns="http://purl.org/rss/1.0/"> + +<channel rdf:about="http://primates.ximian.com/~ravi/BoozeLog/"> +<title>Vignesh Blogs Here</title> +<link>http://primates.ximian.com/~ravi/BoozeLog/</link> +<description></description> +<language>en-us</language> +<webMaster></webMaster> +<lastBuildDate>2002-10-11T00:50:42-06:00</lastBuildDate> +<pubDate>2002-10-12T20:19:57-06:00</pubDate> +<admin:generatorAgent rdf:resource="http://www.movabletype.org/?v=2.21" /> + +<items> +<rdf:Seq><rdf:li rdf:resource="http://primates.ximian.com/~ravi/BoozeLog/archives/000025.html" /> +<rdf:li rdf:resource="http://primates.ximian.com/~ravi/BoozeLog/archives/000024.html" /> +<rdf:li rdf:resource="http://primates.ximian.com/~ravi/BoozeLog/archives/000023.html" /> +<rdf:li rdf:resource="http://primates.ximian.com/~ravi/BoozeLog/archives/000020.html" /> +<rdf:li rdf:resource="http://primates.ximian.com/~ravi/BoozeLog/archives/000013.html" /> +<rdf:li rdf:resource="http://primates.ximian.com/~ravi/BoozeLog/archives/000012.html" /> +<rdf:li rdf:resource="http://primates.ximian.com/~ravi/BoozeLog/archives/000011.html" /> +<rdf:li rdf:resource="http://primates.ximian.com/~ravi/BoozeLog/archives/000008.html" /> +</rdf:Seq> +</items> + +</channel> + +<item rdf:about="http://primates.ximian.com/~ravi/BoozeLog/archives/000025.html"> +<title>Happy Birthday Vidya</title> +<description>Today is Vidya's birthday ! Happy Birthday Vidya! We had a midnight party,as usual, at Swapna's place, though I dont...</description> +<link>http://primates.ximian.com/~ravi/BoozeLog/archives/000025.html</link> +<dc:subject>Blog entry</dc:subject> +<dc:creator>Booze</dc:creator> +<dc:date>2002-10-11T00:50:42-06:00</dc:date> +</item> +<item rdf:about="http://primates.ximian.com/~ravi/BoozeLog/archives/000024.html"> +<title>Way to go, Shaastra!</title> +<description>On Flash Back mode now: Shaastra is the technical festival at my alma mater, IIT Madras, that replaced the old,...</description> +<link>http://primates.ximian.com/~ravi/BoozeLog/archives/000024.html</link> +<dc:subject>Blog entry</dc:subject> +<dc:creator>Booze</dc:creator> +<dc:date>2002-10-10T11:52:02-06:00</dc:date> +</item> +<item rdf:about="http://primates.ximian.com/~ravi/BoozeLog/archives/000023.html"> +<title>Back and Forth in Time</title> +<description>The blog is going to be a little skewed in time for the next coupla days.. Inspite of my laziness,...</description> +<link>http://primates.ximian.com/~ravi/BoozeLog/archives/000023.html</link> +<dc:subject>Blog entry</dc:subject> +<dc:creator>Booze</dc:creator> +<dc:date>2002-10-09T23:47:19-06:00</dc:date> +</item> +<item rdf:about="http://primates.ximian.com/~ravi/BoozeLog/archives/000020.html"> +<title>Frisco Rocks!</title> +<description>If there be any reason the blog hasnt been updated,it is simply because I am enjoying my trip to San...</description> +<link>http://primates.ximian.com/~ravi/BoozeLog/archives/000020.html</link> +<dc:subject>Blog entry</dc:subject> +<dc:creator>Booze</dc:creator> +<dc:date>2002-10-03T23:53:16-06:00</dc:date> +</item> +<item rdf:about="http://primates.ximian.com/~ravi/BoozeLog/archives/000013.html"> +<title>Think but not make thoughts your aim</title> +<description>A line from Rudyard Kipling's IF : would sum up my feelings for today, a lot of thinking from morning...</description> +<link>http://primates.ximian.com/~ravi/BoozeLog/archives/000013.html</link> +<dc:subject>Blog entry</dc:subject> +<dc:creator>Booze</dc:creator> +<dc:date>2002-09-28T22:48:09-06:00</dc:date> +</item> +<item rdf:about="http://primates.ximian.com/~ravi/BoozeLog/archives/000012.html"> +<title>New ARM but...</title> +<description>ARM stands for Advanced Recording Model, a simulation software that I use for my work, and I have been tinkering...</description> +<link>http://primates.ximian.com/~ravi/BoozeLog/archives/000012.html</link> +<dc:subject>Blog entry</dc:subject> +<dc:creator>Booze</dc:creator> +<dc:date>2002-09-27T22:36:28-06:00</dc:date> +</item> +<item rdf:about="http://primates.ximian.com/~ravi/BoozeLog/archives/000011.html"> +<title>A much needed break</title> +<description>Slowly got over the hangover of Sandhya's departure and moved to more mundane things in life : assignments, submissions and...</description> +<link>http://primates.ximian.com/~ravi/BoozeLog/archives/000011.html</link> +<dc:subject>Blog entry</dc:subject> +<dc:creator>Booze</dc:creator> +<dc:date>2002-09-26T23:05:46-06:00</dc:date> +</item> +<item rdf:about="http://primates.ximian.com/~ravi/BoozeLog/archives/000008.html"> +<title>Here we go !</title> +<description>My first attempts at Blogging, the idea was introduced to me by Ravi Pratap. MoveableType really makes it easy and...</description> +<link>http://primates.ximian.com/~ravi/BoozeLog/archives/000008.html</link> +<dc:subject>Blog entry</dc:subject> +<dc:creator>Booze</dc:creator> +<dc:date>2002-09-25T19:27:22-06:00</dc:date> +</item> + + +</rdf:RDF> diff --git a/ACEXML/examples/SAXPrint/ns.svc.conf.xml b/ACEXML/examples/SAXPrint/ns.svc.conf.xml index db1821d7ac0..980ef21de92 100644 --- a/ACEXML/examples/SAXPrint/ns.svc.conf.xml +++ b/ACEXML/examples/SAXPrint/ns.svc.conf.xml @@ -5,7 +5,7 @@ <params>-p 4911</params> </static> -<dynamic id="Test_Task" type="service_object"> A & +<dynamic id="Test_Task" type="service_object"> A &lt; <initializer path="CCM_App" init="_make_Test_Task"> <params>-p 3000</params> </initializer> diff --git a/ACEXML/examples/SAXPrint/svc.conf.xml b/ACEXML/examples/SAXPrint/svc.conf.xml index 152f3b44406..5296e5cac35 100644 --- a/ACEXML/examples/SAXPrint/svc.conf.xml +++ b/ACEXML/examples/SAXPrint/svc.conf.xml @@ -1,12 +1,12 @@ <?xml version="1.0"?> <!-- This is a test XML file. Most of the stuff here don't make any sense at all --> -<!DOCTYPE ACE_Svc_Conf PUBLIC 'GOODSAM' 'http://ace.cs.wustl.edu/dtd/ACE_SVCCONF.DTD' +<!DOCTYPE ACE_Svc_Conf PUBLIC 'GOODSAM' '../../apps/svcconf/svcconf.dtd' [ <!NOTATION goody PUBLIC 'NBC' 'http://hardcoreace.com/'> <!NOTATION frodo PUBLIC 'ABC'> <!NOTATION bilbo SYSTEM "C:/ACE-GUIDELINE"> <!ENTITY ccm 'CCM_App'> - <!ENTITY pippin PUBLIC 'GOTO' 'http://taozen.com/' NDATA NBC> + <!ENTITY pippin PUBLIC 'GOTO' 'http://taozen.com/' NDATA goody> <!ENTITY sam PUBLIC 'SHIRE' 'http://taozen.com/'> <!ENTITY gandolf SYSTEM 'D:/RINGS.DOT'> <!ELEMENT GOOBEGONE EMPTY> diff --git a/ACEXML/examples/svcconf/Makefile b/ACEXML/examples/svcconf/Makefile new file mode 100644 index 00000000000..d476cd46d25 --- /dev/null +++ b/ACEXML/examples/svcconf/Makefile @@ -0,0 +1,14 @@ +# $Id$ +#---------------------------------------------------------------------------- +# GNU ACE Workspace +#---------------------------------------------------------------------------- + +include $(ACE_ROOT)/include/makeinclude/macros.GNU +TARGETS_NESTED := $(TARGETS_NESTED:.nested=) + +$(TARGETS_NESTED): +ifneq (Windows,$(findstring Windows,$(OS))) + @$(MAKE) -f Makefile.Svcconf -C . $(@); +else + -@cmd /c "$(MAKE) -f Makefile.Svcconf -C . $(@)" +endif diff --git a/ACEXML/examples/svcconf/Makefile.Svcconf b/ACEXML/examples/svcconf/Makefile.Svcconf new file mode 100644 index 00000000000..94317241e70 --- /dev/null +++ b/ACEXML/examples/svcconf/Makefile.Svcconf @@ -0,0 +1,56 @@ +#---------------------------------------------------------------------------- +# GNU Makefile +#---------------------------------------------------------------------------- +MAKEFILE = Makefile.Svcconf +DEPENDENCY_FILE = .depend.Makefile.Svcconf +BIN_UNCHECKED = main + + + +FILES = \ + main \ + Svcconf_Handler +#---------------------------------------------------------------------------- +# Include macros and targets +#---------------------------------------------------------------------------- + +include $(ACE_ROOT)/include/makeinclude/wrapper_macros.GNU + +BIN = $(BIN_UNCHECKED) + +OBJS = $(addsuffix .o, $(notdir $(FILES))) +SRC = $(addsuffix .cpp, $(FILES)) +ACELIB = -lACE + +include $(ACE_ROOT)/include/makeinclude/macros.GNU +include $(ACE_ROOT)/include/makeinclude/rules.common.GNU +include $(ACE_ROOT)/include/makeinclude/rules.nonested.GNU +include $(ACE_ROOT)/include/makeinclude/rules.local.GNU + +CPPFLAGS += -I../../.. + + +ifeq ($(static_libs),1) + ifneq ($(LIB),) + CPPFLAGS += -DACE_AS_STATIC_LIBS + endif +endif + + +LDFLAGS += -L../../../ACEXML/apps/svcconf -L../../../ACEXML/common -L../../../ACEXML/parser/parser -L../../../ace + + + +LDLIBS = -lACEXML_XML_Svc_Conf_Parser -lACEXML_Parser -lACEXML +#---------------------------------------------------------------------------- +# Local targets +#---------------------------------------------------------------------------- + +$(BIN): $(addprefix $(VDIR), $(OBJS)) + $(LINK.cc) $(LDFLAGS) $(CC_OUTPUT_FLAG) $@ $^ $(VLDLIBS) $(POSTLINK) + +realclean: clean +ifneq ($(GENERATED_DIRTY),) + -$(RM) -r $(GENERATED_DIRTY) +endif + diff --git a/ACEXML/examples/svcconf/Makefile.Svcconf.bor b/ACEXML/examples/svcconf/Makefile.Svcconf.bor new file mode 100644 index 00000000000..e9394ccaf10 --- /dev/null +++ b/ACEXML/examples/svcconf/Makefile.Svcconf.bor @@ -0,0 +1,55 @@ +# Makefile for building the main exe with Borland C++ Builder + +NAME = main + +NAME = main + + +OBJFILES = \ + $(OBJDIR)\Svcconf_Handler.obj \ + $(OBJDIR)\main.obj + +EXTERNAL_LIBS = \ + \ + +LFLAGS = \ + -j..\..\..\ACEXML\apps\svcconf\$(CONFIG_SUBDIR) -j..\..\..\ACEXML\apps\svcconf \ + -L..\..\..\ACEXML\apps\svcconf\$(CONFIG_SUBDIR) -L..\..\..\ACEXML\apps\svcconf \ + -j..\..\..\ACEXML\common\$(CONFIG_SUBDIR) -j..\..\..\ACEXML\common \ + -L..\..\..\ACEXML\common\$(CONFIG_SUBDIR) -L..\..\..\ACEXML\common \ + -j..\..\..\ACEXML\parser\parser\$(CONFIG_SUBDIR) -j..\..\..\ACEXML\parser\parser \ + -L..\..\..\ACEXML\parser\parser\$(CONFIG_SUBDIR) -L..\..\..\ACEXML\parser\parser \ + -j..\..\..\ace\$(CONFIG_SUBDIR) -j..\..\..\ace \ + -L..\..\..\ace\$(CONFIG_SUBDIR) -L..\..\..\ace \ + -j$(CORE_BINDIR) \ + -L$(CORE_BINDIR) + +LIBFILES = \ + ACEXML_XML_Svc_Conf_Parser$(LIB_DECORATOR).lib \ + ACEXML_Parser$(LIB_DECORATOR).lib \ + ACEXML$(LIB_DECORATOR).lib \ + ACE$(LIB_DECORATOR).lib \ + $(EXTERNAL_LIBS) + + + +!ifdef STATIC +LIB_FLAGS = -DACE_AS_STATIC_LIBS +DLL_FLAGS = +!else +LIB_FLAGS = +DLL_FLAGS = +!endif + +CFLAGS = \ + -I..\..\.. \ + $(LIB_FLAGS) \ + $(DLL_FLAGS) + +CPPDIR = . + +INCLUDES = \ + Svcconf_Handler.h \ + Svcconf_Handler.i + +!include <$(ACE_ROOT)\include\makeinclude\build_exe.bor> diff --git a/ACEXML/examples/svcconf/Makefile.bor b/ACEXML/examples/svcconf/Makefile.bor index 91b14f910cb..3f477c204a4 100644 --- a/ACEXML/examples/svcconf/Makefile.bor +++ b/ACEXML/examples/svcconf/Makefile.bor @@ -1,24 +1,20 @@ -# -# $Id$ -# Makefile for building the svcconf example -# +#---------------------------------------------------------------------------- +# Borland Workspace +#---------------------------------------------------------------------------- -NAME = Svcconf +!include <$(ACE_ROOT)\include\makeinclude\make_flags.bor> -OBJFILES = \ - $(OBJDIR)\Svcconf_Handler.obj \ - $(OBJDIR)\main.obj +all: + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.Svcconf.bor all -CFLAGS = \ - $(ACE_CFLAGS) \ - $(ACE_XML_CFLAGS) \ - $(ACE_XML_PARSER_CFLAGS) +clean: + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.Svcconf.bor clean -CPPDIR = . +realclean: + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.Svcconf.bor realclean -LIBFILES = \ - $(ACE_LIB) \ - $(ACE_XML_LIB) \ - $(ACE_XML_PARSER_LIB) +install: + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.Svcconf.bor install -!include <$(ACE_ROOT)\include\makeinclude\build_exe.bor> +regenerate: + D:\Perl\bin\perl.exe D:\ACE_wrappers\bin\mwc.pl -type borland -recurse diff --git a/ACEXML/examples/svcconf/Svcconf.dsp b/ACEXML/examples/svcconf/Svcconf.dsp index 15911671e1c..fe7b170cdae 100644 --- a/ACEXML/examples/svcconf/Svcconf.dsp +++ b/ACEXML/examples/svcconf/Svcconf.dsp @@ -1,25 +1,26 @@ -# Microsoft Developer Studio Project File - Name="Svcconf" - Package Owner=<4>
+# Microsoft Developer Studio Project File - Name="Svcconf EXE" - Package Owner=<4>
# Microsoft Developer Studio Generated Build File, Format Version 6.00
# ** DO NOT EDIT **
# TARGTYPE "Win32 (x86) Console Application" 0x0103
-CFG=Svcconf - Win32 Debug
+CFG=Svcconf EXE - Win32 Debug
!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
+!MESSAGE run the tool that generated this project file and specify the
+!MESSAGE nmake output type. You can then use the following command:
+!MESSAGE
!MESSAGE NMAKE /f "Svcconf.mak".
-!MESSAGE
+!MESSAGE
!MESSAGE You can specify a configuration when running NMAKE
!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "Svcconf.mak" CFG="Svcconf - Win32 Debug"
-!MESSAGE
+!MESSAGE
+!MESSAGE NMAKE /f "Svcconf.mak" CFG="Svcconf EXE - Win32 Debug"
+!MESSAGE
!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "Svcconf - Win32 Release" (based on "Win32 (x86) Console Application")
-!MESSAGE "Svcconf - Win32 Debug" (based on "Win32 (x86) Console Application")
-!MESSAGE
+!MESSAGE
+!MESSAGE "Svcconf EXE - Win32 Release" (based on "Win32 (x86) Console Application")
+!MESSAGE "Svcconf EXE - Win32 Debug" (based on "Win32 (x86) Console Application")
+!MESSAGE
# Begin Project
# PROP AllowPerConfigDependencies 0
@@ -28,63 +29,45 @@ CFG=Svcconf - Win32 Debug CPP=cl.exe
RSC=rc.exe
-!IF "$(CFG)" == "Svcconf - Win32 Release"
+!IF "$(CFG)" == "Svcconf EXE - Win32 Release"
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release"
-# PROP BASE Intermediate_Dir "Release"
-# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 0
# PROP Output_Dir "Release"
-# PROP Intermediate_Dir "Release"
-# PROP Ignore_Export_Lib 0
+# PROP Intermediate_Dir "Release\Svcconf"
# PROP Target_Dir ""
-# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\..\\" /I "..\..\..\\" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
-# ADD BASE RSC /l 0x409 /d "NDEBUG"
-# ADD RSC /l 0x409 /d "NDEBUG"
+# ADD CPP /nologo /W3 /GX /O2 /MD /GR /I "..\..\.." /D NDEBUG=1 /D WIN32=1 /D _CONSOLE=1 /FD /c
+# SUBTRACT CPP /YX
+# ADD RSC /l 0x409 /d NDEBUG=1 /i "..\..\.."
BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
+# ADD BSC32 /nologo
LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386
-# ADD LINK32 ace.lib ACEXML.lib ACEXML_Parser.lib /nologo /subsystem:console /machine:I386 /libpath:"..\..\..\ace" /libpath:"..\..\Common" /libpath:"..\..\parser\parser"
+# ADD LINK32 advapi32.lib user32.lib /INCREMENTAL:NO ACEXML_XML_Svc_Conf_Parser.lib ACEXML_Parser.lib ACEXML.lib ACE.lib /libpath:"..\..\..\ACEXML\apps\svcconf" /libpath:"..\..\..\ACEXML\common" /libpath:"..\..\..\ACEXML\parser\parser" /libpath:"..\..\..\ace" /nologo /version:5.3.1 /subsystem:console /pdb:"Release\main.pdb" /machine:I386 /out:"Release\main.exe"
-!ELSEIF "$(CFG)" == "Svcconf - Win32 Debug"
+!ELSEIF "$(CFG)" == "Svcconf EXE - Win32 Debug"
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug"
-# PROP BASE Intermediate_Dir "Debug"
-# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 1
-# PROP Output_Dir ""
-# PROP Intermediate_Dir "Debug"
-# PROP Ignore_Export_Lib 1
+# PROP Output_Dir "."
+# PROP Intermediate_Dir "Debug\Svcconf"
# PROP Target_Dir ""
-# ADD BASE CPP /nologo /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /Zi /Od /I "..\..\\" /I "..\..\..\\" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
-# ADD BASE RSC /l 0x409 /d "_DEBUG"
-# ADD RSC /l 0x409 /d "_DEBUG"
+# ADD CPP /nologo /W3 /Gm /GX /Zi /Od /MDd /GR /Gy /I "..\..\.." /D _DEBUG=1 /D WIN32=1 /D _CONSOLE=1 /FD /c
+# SUBTRACT CPP /YX
+# ADD RSC /l 0x409 /d _DEBUG=1 /i "..\..\.."
BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
+# ADD BSC32 /nologo
LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 aced.lib ACEXMLd.lib ACEXML_Parserd.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept /libpath:"..\..\..\ace" /libpath:"..\..\Common" /libpath:"..\..\parser\parser"
+# ADD LINK32 advapi32.lib user32.lib /INCREMENTAL:NO ACEXML_XML_Svc_Conf_Parserd.lib ACEXML_Parserd.lib ACEXMLd.lib ACEd.lib /libpath:"..\..\..\ACEXML\apps\svcconf" /libpath:"..\..\..\ACEXML\common" /libpath:"..\..\..\ACEXML\parser\parser" /libpath:"..\..\..\ace" /nologo /version:5.3.1 /subsystem:console /pdb:".\main.pdb" /debug /machine:I386 /out:".\main.exe"
-!ENDIF
+!ENDIF
# Begin Target
-# Name "Svcconf - Win32 Release"
-# Name "Svcconf - Win32 Debug"
+# Name "Svcconf EXE - Win32 Release"
+# Name "Svcconf EXE - Win32 Debug"
# Begin Group "Source Files"
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
+# PROP Default_Filter "cpp;cxx;c"
# Begin Source File
SOURCE=.\main.cpp
@@ -96,15 +79,27 @@ SOURCE=.\Svcconf_Handler.cpp # End Group
# Begin Group "Header Files"
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
+# PROP Default_Filter "h;hpp;hxx;hh"
# Begin Source File
SOURCE=.\Svcconf_Handler.h
# End Source File
# End Group
-# Begin Group "Resource Files"
+# Begin Group "Inline Files"
-# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
+# PROP Default_Filter "i;inl"
+# Begin Source File
+
+SOURCE=.\Svcconf_Handler.i
+# End Source File
+# End Group
+# Begin Group "Documentation"
+
+# PROP Default_Filter ""
+# Begin Source File
+
+SOURCE=.\README
+# End Source File
# End Group
# End Target
# End Project
diff --git a/ACEXML/examples/svcconf/Svcconf.mpc b/ACEXML/examples/svcconf/Svcconf.mpc new file mode 100644 index 00000000000..4210bafc0c0 --- /dev/null +++ b/ACEXML/examples/svcconf/Svcconf.mpc @@ -0,0 +1,5 @@ +project (Svcconf) : aceexe, acexml { + depends += ACEXML_XML_Svc_Conf_Parser + libs += ACEXML_XML_Svc_Conf_Parser + libpaths += $(ACE_ROOT)/ACEXML/apps/svcconf +} diff --git a/ACEXML/examples/svcconf/main.cpp b/ACEXML/examples/svcconf/main.cpp index d23ffcbe91a..8da75e2f49e 100644 --- a/ACEXML/examples/svcconf/main.cpp +++ b/ACEXML/examples/svcconf/main.cpp @@ -35,7 +35,6 @@ ACE_TMAIN (int argc, ACE_TCHAR *argv[]) ACE_ERROR_RETURN ((LM_ERROR, "No filename specified\n"), -1); ACEXML_DefaultHandler *handler = 0; - auto_ptr<ACEXML_DefaultHandler> cleanup_handler (handler); ACEXML_CharStream *stm = 0; ACEXML_FileCharStream *fstm = 0; ACE_NEW_RETURN (fstm, @@ -53,6 +52,8 @@ ACE_TMAIN (int argc, ACE_TCHAR *argv[]) ACEXML_Svcconf_Handler (), -1); + auto_ptr<ACEXML_DefaultHandler> cleanup_handler (handler); + ACEXML_Parser parser; ACEXML_InputSource input(stm); diff --git a/ACEXML/parser/Makefile b/ACEXML/parser/Makefile deleted file mode 100644 index 9a519bc492b..00000000000 --- a/ACEXML/parser/Makefile +++ /dev/null @@ -1,17 +0,0 @@ -#---------------------------------------------------------------------------- -# $Id$ -# -# Makefile for the client programs that test the ACE network services -#---------------------------------------------------------------------------- - -DIRS = parser - -#---------------------------------------------------------------------------- -# Include macros and targets -#---------------------------------------------------------------------------- - -include $(ACE_ROOT)/include/makeinclude/wrapper_macros.GNU -include $(ACE_ROOT)/include/makeinclude/macros.GNU -include $(ACE_ROOT)/include/makeinclude/rules.common.GNU -include $(ACE_ROOT)/include/makeinclude/rules.nested.GNU -include $(ACE_ROOT)/include/makeinclude/rules.nolocal.GNU diff --git a/ACEXML/parser/debug_validator/Debug_Validator.dsp b/ACEXML/parser/debug_validator/Debug_Validator.dsp deleted file mode 100644 index ee0f98624c6..00000000000 --- a/ACEXML/parser/debug_validator/Debug_Validator.dsp +++ /dev/null @@ -1,145 +0,0 @@ -# Microsoft Developer Studio Project File - Name="Debug_Validator" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=Debug_Validator - Win32 Debug
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "Debug_Validator.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "Debug_Validator.mak" CFG="Debug_Validator - Win32 Debug"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "Debug_Validator - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "Debug_Validator - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "Debug_Validator - Win32 Release"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release"
-# PROP BASE Intermediate_Dir "Release"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir ""
-# PROP Intermediate_Dir "Release"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "DEBUG_VALIDATOR_EXPORTS" /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\..\.." /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "ACEXML_DEBUG_DTD_MANAGER_BUILD_DLL" /FD /c
-# SUBTRACT CPP /YX
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x409 /d "NDEBUG"
-# ADD RSC /l 0x409 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
-# ADD LINK32 ace.lib ACEXML.lib /nologo /dll /machine:I386 /out:"../../../bin/ACEXML_Debug_DTD_Manager.dll" /libpath:"../../../ace" /libpath:"../../Common"
-
-!ELSEIF "$(CFG)" == "Debug_Validator - Win32 Debug"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug"
-# PROP BASE Intermediate_Dir "Debug"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir ""
-# PROP Intermediate_Dir "Debug"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "DEBUG_VALIDATOR_EXPORTS" /YX /FD /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /Zi /Od /I "..\..\.." /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "ACEXML_DEBUG_DTD_MANAGER_BUILD_DLL" /FD /c
-# SUBTRACT CPP /YX
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x409 /d "_DEBUG"
-# ADD RSC /l 0x409 /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 aced.lib ACEXMLd.lib /nologo /dll /debug /machine:I386 /out:"../../../bin/ACEXML_Debug_DTD_Managerd.dll" /pdbtype:sept /libpath:"../../../ace" /libpath:"../../Common"
-
-!ENDIF
-
-# Begin Target
-
-# Name "Debug_Validator - Win32 Release"
-# Name "Debug_Validator - Win32 Debug"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\Debug_Attributes_Builder.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\Debug_DTD_Manager.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\Debug_Element_Builder.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\Element_Tree.cpp
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\Debug_Attributes_Builder.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\Debug_DTD_Manager.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\Debug_DTD_Manager_Export.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\Debug_Element_Builder.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\Element_Tree.h
-# End Source File
-# End Group
-# Begin Group "Resource Files"
-
-# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
-# End Group
-# Begin Source File
-
-SOURCE=.\Element_Tree.i
-# End Source File
-# End Target
-# End Project
diff --git a/ACEXML/parser/debug_validator/Makefile.bor b/ACEXML/parser/debug_validator/Makefile.bor deleted file mode 100644 index 08ee7c36e43..00000000000 --- a/ACEXML/parser/debug_validator/Makefile.bor +++ /dev/null @@ -1,22 +0,0 @@ -# Makefile for building the debug_validator - -NAME = ACEXML_Debug_DTD_Manager - -OBJFILES = \ - $(OBJDIR)\Debug_Attributes_Builder.obj \ - $(OBJDIR)\Debug_DTD_Manager.obj \ - $(OBJDIR)\Debug_Element_Builder.obj \ - $(OBJDIR)\Element_Tree.obj - -CFLAGS = \ - $(ACE_CFLAGS) \ - $(ACE_XML_CFLAGS) \ - -DACEXML_DEBUG_DTD_MANAGER_BUILD_DLL - -CPPDIR = .;.. - -LIBFILES = \ - $(ACE_LIB) \ - $(ACE_XML_LIB) - -!include <$(ACE_ROOT)\include\makeinclude\build_core_library.bor> diff --git a/ACEXML/parser/parser/ACEXML_Parser.dsp b/ACEXML/parser/parser/ACEXML_Parser.dsp new file mode 100644 index 00000000000..1f96c9d1122 --- /dev/null +++ b/ACEXML/parser/parser/ACEXML_Parser.dsp @@ -0,0 +1,131 @@ +# Microsoft Developer Studio Project File - Name="ACEXML_Parser DLL" - Package Owner=<4>
+# Microsoft Developer Studio Generated Build File, Format Version 6.00
+# ** DO NOT EDIT **
+
+# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
+
+CFG=ACEXML_Parser DLL - Win32 Debug
+!MESSAGE This is not a valid makefile. To build this project using NMAKE,
+!MESSAGE run the tool that generated this project file and specify the
+!MESSAGE nmake output type. You can then use the following command:
+!MESSAGE
+!MESSAGE NMAKE /f "ACEXML_Parser.mak".
+!MESSAGE
+!MESSAGE You can specify a configuration when running NMAKE
+!MESSAGE by defining the macro CFG on the command line. For example:
+!MESSAGE
+!MESSAGE NMAKE /f "ACEXML_Parser.mak" CFG="ACEXML_Parser DLL - Win32 Debug"
+!MESSAGE
+!MESSAGE Possible choices for configuration are:
+!MESSAGE
+!MESSAGE "ACEXML_Parser DLL - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library")
+!MESSAGE "ACEXML_Parser DLL - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library")
+!MESSAGE
+
+# Begin Project
+# PROP AllowPerConfigDependencies 0
+# PROP Scc_ProjName ""
+# PROP Scc_LocalPath ""
+CPP=cl.exe
+RSC=rc.exe
+
+!IF "$(CFG)" == "ACEXML_Parser DLL - Win32 Release"
+
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 0
+# PROP Output_Dir "."
+# PROP Intermediate_Dir "Release\ACEXML_Parser"
+# PROP Ignore_Export_Lib 0
+# PROP Target_Dir ""
+# ADD CPP /nologo /W3 /GX /O2 /MD /Zi /GR /I "..\..\.." /D NDEBUG=1 /D WIN32=1 /D _WINDOWS=1 /D ACEXML_PARSER_BUILD_DLL=1 /FD /c
+# SUBTRACT CPP /YX
+# ADD RSC /l 0x409 /d NDEBUG=1 /i "..\..\.."
+BSC32=bscmake.exe
+# ADD BSC32 /nologo /o".\ACEXML_Parser.bsc"
+LINK32=link.exe
+# ADD LINK32 advapi32.lib user32.lib /INCREMENTAL:NO ACEXML.lib ACE.lib /libpath:"..\..\..\ACEXML\common" /libpath:"..\..\..\ace" /nologo /version:5.3.1 /subsystem:windows /pdb:"..\..\..\bin\ACEXML_Parser.pdb" /dll /machine:I386 /out:"..\..\..\bin\ACEXML_Parser.dll"
+
+!ELSEIF "$(CFG)" == "ACEXML_Parser DLL - Win32 Debug"
+
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 1
+# PROP Output_Dir "."
+# PROP Intermediate_Dir "Debug\ACEXML_Parser"
+# PROP Ignore_Export_Lib 0
+# PROP Target_Dir ""
+# ADD CPP /nologo /W3 /Gm /GX /Zi /Od /MDd /GR /Gy /I "..\..\.." /D _DEBUG=1 /D WIN32=1 /D _WINDOWS=1 /D ACEXML_PARSER_BUILD_DLL=1 /FD /c
+# SUBTRACT CPP /Fr /YX
+# ADD RSC /l 0x409 /d _DEBUG=1 /i "..\..\.."
+BSC32=bscmake.exe
+# ADD BSC32 /nologo /o".\ACEXML_Parser.bsc"
+LINK32=link.exe
+# ADD LINK32 advapi32.lib user32.lib /INCREMENTAL:NO ACEXMLd.lib ACEd.lib /libpath:"..\..\..\ACEXML\common" /libpath:"..\..\..\ace" /nologo /version:5.3.1 /subsystem:windows /pdb:"..\..\..\bin\ACEXML_Parserd.pdb" /dll /debug /machine:I386 /out:"..\..\..\bin\ACEXML_Parserd.dll"
+
+!ENDIF
+
+# Begin Target
+
+# Name "ACEXML_Parser DLL - Win32 Release"
+# Name "ACEXML_Parser DLL - Win32 Debug"
+# Begin Group "Source Files"
+
+# PROP Default_Filter "cpp;cxx;c"
+# Begin Source File
+
+SOURCE=.\Entity_Manager.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\Parser.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\ParserContext.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\ParserInternals.cpp
+# End Source File
+# End Group
+# Begin Group "Header Files"
+
+# PROP Default_Filter "h;hpp;hxx;hh"
+# Begin Source File
+
+SOURCE=.\Entity_Manager.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\Parser.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\Parser_export.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\ParserContext.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\ParserInternals.h
+# End Source File
+# End Group
+# Begin Group "Inline Files"
+
+# PROP Default_Filter "i;inl"
+# Begin Source File
+
+SOURCE=.\Entity_Manager.i
+# End Source File
+# Begin Source File
+
+SOURCE=.\Parser.i
+# End Source File
+# Begin Source File
+
+SOURCE=.\ParserContext.inl
+# End Source File
+# End Group
+# End Target
+# End Project
diff --git a/ACEXML/parser/parser/Entity_Manager.cpp b/ACEXML/parser/parser/Entity_Manager.cpp index d0c86862805..0b781b6f0e4 100644 --- a/ACEXML/parser/parser/Entity_Manager.cpp +++ b/ACEXML/parser/parser/Entity_Manager.cpp @@ -2,45 +2,17 @@ #include "ACEXML/parser/parser/Entity_Manager.h" +static const ACEXML_Char empty_string[] = { 0 }; + #if !defined (__ACEXML_INLINE__) # include "ACEXML/parser/parser/Entity_Manager.i" #endif /* __ACEXML_INLINE__ */ -static const ACEXML_Char amp_name[] = {'a', 'm', 'p', 0 }; -static const ACEXML_Char amp_value[] = {'&', 0}; -static const ACEXML_Char lt_name[] = {'l', 't', 0}; -static const ACEXML_Char lt_value[] = {'<', 0}; -static const ACEXML_Char gt_name[] = {'g', 't', 0}; -static const ACEXML_Char gt_value[] = {'>', 0}; -static const ACEXML_Char apos_name[] = {'a', 'p', 'o', 's', 0}; -static const ACEXML_Char apos_value[] = {'\'', 0}; -static const ACEXML_Char quot_name[] = {'q', 'u', 'o', 't', 0}; -static const ACEXML_Char quot_value[] = {'"', 0}; ACEXML_Entity_Manager::ACEXML_Entity_Manager (void) : entities_ () { - // @@ No way to know if these bindings succeed or not. - - ACEXML_String ampname (amp_name, 0, 0); - ACEXML_String ampvalue (amp_value, 0, 0); - this->entities_.bind (ampname, ampvalue); - - ACEXML_String ltname (lt_name, 0, 0); - ACEXML_String ltvalue (lt_value, 0, 0); - this->entities_.bind (ltname, ltvalue); - - ACEXML_String gtname (gt_name, 0, 0); - ACEXML_String gtvalue (gt_value, 0, 0); - this->entities_.bind (gtname, gtvalue); - - ACEXML_String aposname (apos_name, 0, 0); - ACEXML_String aposvalue (apos_value, 0, 0); - this->entities_.bind (aposname, aposvalue); - ACEXML_String quotname (quot_name, 0, 0); - ACEXML_String quotvalue (quot_value, 0, 0); - this->entities_.bind (quotname, quotvalue); } ACEXML_Entity_Manager::~ACEXML_Entity_Manager (void) diff --git a/ACEXML/parser/parser/Entity_Manager.h b/ACEXML/parser/parser/Entity_Manager.h index 9bcfcc443a3..dfe084ad973 100644 --- a/ACEXML/parser/parser/Entity_Manager.h +++ b/ACEXML/parser/parser/Entity_Manager.h @@ -7,6 +7,7 @@ * $Id$ * * @author Nanbor Wang <nanbor@cs.wustl.edu> + * @author Krishnakumar B <kitty@cs.wustl.edu> */ //============================================================================= @@ -45,6 +46,12 @@ typedef ACE_Hash_Map_Reverse_Iterator_Ex<ACEXML_String, ACE_Equal_To<ACEXML_String>, ACE_Null_Mutex> ACEXML_ENTITIES_MANAGER_REVERSE_ITER; +typedef ACE_Hash_Map_Bucket_Iterator<ACEXML_String, + ACEXML_String, + ACE_Hash<ACEXML_String>, + ACE_Equal_To<ACEXML_String>, + ACE_Null_Mutex> ACEXML_ENTITY_ENTRY_ITERATOR; + /** * @class ACEXML_Entity_Manager Entity_Manager.h "ACEXML/parser/parser/Entity_Manager.h" * @@ -62,11 +69,21 @@ public: ~ACEXML_Entity_Manager (void); /// Add a new entity declaration. - int add_entity (const ACEXML_Char *ref, - const ACEXML_Char *value); + int add_entity (const ACEXML_Char *ref, const ACEXML_Char *value); /// Resolve an entity reference. - const ACEXML_String *resolve_entity (const ACEXML_Char *ref); + const ACEXML_Char* resolve_entity (const ACEXML_Char *ref); + + /// Resolve an entity reference and return the tuple of @c systemId and + /// @c publicId + int resolve_entity (const ACEXML_Char* ref, ACEXML_Char*& systemId, + ACEXML_Char*& publicId); + + /// Number of items in the Entity Manager + const size_t size(void) const; + + /// Reset the state + int reset (void); private: ACEXML_ENTITIES_MANAGER entities_; diff --git a/ACEXML/parser/parser/Entity_Manager.i b/ACEXML/parser/parser/Entity_Manager.i index 696b82b64e4..24b507eb96a 100644 --- a/ACEXML/parser/parser/Entity_Manager.i +++ b/ACEXML/parser/parser/Entity_Manager.i @@ -9,13 +9,48 @@ ACEXML_Entity_Manager::add_entity (const ACEXML_Char *ref, return this->entities_.bind (name, value); } -ACEXML_INLINE const ACEXML_String * +ACEXML_INLINE const ACEXML_Char* ACEXML_Entity_Manager::resolve_entity (const ACEXML_Char *ref) { ACEXML_ENTITY_ENTRY *entry; if (this->entities_.find (ACEXML_String (ref, 0, 0), entry) == 0) - return &entry->int_id_; + return entry->int_id_.c_str(); return 0; } + +ACEXML_INLINE int +ACEXML_Entity_Manager::resolve_entity (const ACEXML_Char* ref, + ACEXML_Char*& systemId, + ACEXML_Char*& publicId) +{ + publicId = systemId = 0; + ACEXML_ENTITY_ENTRY_ITERATOR iter (this->entities_, ref); + ACEXML_ENTITY_ENTRY_ITERATOR end (this->entities_, ref, 1); + + if (iter != end) + { + systemId = ACE_const_cast (ACEXML_Char*, (*iter).int_id_.c_str()); + ++iter; + if (iter != end) + publicId = ACE_const_cast (ACEXML_Char*, (*iter).int_id_.c_str()); + return 0; + } + return -1; +} + +ACEXML_INLINE int +ACEXML_Entity_Manager::reset (void) +{ + if (this->entities_.close() < 0 || this->entities_.open() < 0) + return -1; + return 0; +} + + +ACEXML_INLINE const size_t +ACEXML_Entity_Manager::size (void) const +{ + return this->entities_.current_size(); +} diff --git a/ACEXML/parser/parser/Makefile b/ACEXML/parser/parser/Makefile index 7e46603004b..f9ea338b367 100644 --- a/ACEXML/parser/parser/Makefile +++ b/ACEXML/parser/parser/Makefile @@ -1,334 +1,14 @@ +# $Id$ #---------------------------------------------------------------------------- -# $Id$ -# -# Makefile for the server-side ACE network services +# GNU ACE Workspace #---------------------------------------------------------------------------- -LIB = libACEXML_Parser.a -SHLIB = libACEXML_Parser.$(SOEXT) +include $(ACE_ROOT)/include/makeinclude/macros.GNU +TARGETS_NESTED := $(TARGETS_NESTED:.nested=) -FILES = Entity_Manager \ - Parser - -DEFS = $(addsuffix .h,$(FILES)) -LSRC = $(addsuffix .cpp,$(FILES)) - -LIBS += -lACEXML $(ACELIB) - -BUILD = $(VLIB) $(VSHLIB) - -#---------------------------------------------------------------------------- -# Include macros and targets -#---------------------------------------------------------------------------- - -include $(ACE_ROOT)/include/makeinclude/wrapper_macros.GNU -include $(ACE_ROOT)/include/makeinclude/macros.GNU -include $(ACE_ROOT)/include/makeinclude/rules.common.GNU -include $(ACE_ROOT)/include/makeinclude/rules.nonested.GNU -include $(ACE_ROOT)/include/makeinclude/rules.lib.GNU -include $(ACE_ROOT)/include/makeinclude/rules.local.GNU - -#---------------------------------------------------------------------------- -# Local targets -#---------------------------------------------------------------------------- - -ifeq ($(shared_libs),1) -ifneq ($(SHLIB),) -CPPFLAGS += -DACEXML_PARSER_BUILD_DLL -endif +$(TARGETS_NESTED): +ifneq (Windows,$(findstring Windows,$(OS))) + @$(MAKE) -f Makefile.ACEXML_Parser -C . $(@); +else + -@cmd /c "$(MAKE) -f Makefile.ACEXML_Parser -C . $(@)" endif - -#---------------------------------------------------------------------------- -# Dependencies -#---------------------------------------------------------------------------- -# DO NOT DELETE THIS LINE -- g++dep uses it. -# DO NOT PUT ANYTHING AFTER THIS LINE, IT WILL GO AWAY. - - -.obj/Entity_Manager.o .obj/Entity_Manager.so .shobj/Entity_Manager.o .shobj/Entity_Manager.so: Entity_Manager.cpp \ - Entity_Manager.h \ - $(ACE_ROOT)/ace/pre.h \ - Parser_export.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - $(ACE_ROOT)/ACEXML/common/XML_Types.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h \ - $(ACE_ROOT)/ace/Trace.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - $(ACE_ROOT)/ace/SString.i \ - $(ACE_ROOT)/ace/Hash_Map_Manager.h \ - $(ACE_ROOT)/ace/Hash_Map_Manager_T.h \ - $(ACE_ROOT)/ace/Functor.h \ - $(ACE_ROOT)/ace/Functor.i \ - $(ACE_ROOT)/ace/Functor_T.h \ - $(ACE_ROOT)/ace/Functor_T.i \ - $(ACE_ROOT)/ace/Functor_T.cpp \ - $(ACE_ROOT)/ace/Hash_Map_Manager_T.i \ - $(ACE_ROOT)/ace/Hash_Map_Manager_T.cpp \ - $(ACE_ROOT)/ace/Service_Config.h \ - $(ACE_ROOT)/ace/Unbounded_Queue.h \ - $(ACE_ROOT)/ace/Unbounded_Queue.inl \ - $(ACE_ROOT)/ace/Unbounded_Queue.cpp \ - $(ACE_ROOT)/ace/XML_Svc_Conf.h \ - $(ACE_ROOT)/ace/Service_Config.i \ - $(ACE_ROOT)/ace/Reactor.h \ - $(ACE_ROOT)/ace/Handle_Set.h \ - $(ACE_ROOT)/ace/Handle_Set.i \ - $(ACE_ROOT)/ace/Timer_Queue.h \ - $(ACE_ROOT)/ace/Timer_Queue_T.h \ - $(ACE_ROOT)/ace/Test_and_Set.h \ - $(ACE_ROOT)/ace/Test_and_Set.i \ - $(ACE_ROOT)/ace/Test_and_Set.cpp \ - $(ACE_ROOT)/ace/Timer_Queue_T.i \ - $(ACE_ROOT)/ace/Timer_Queue_T.cpp \ - $(ACE_ROOT)/ace/Reactor.i \ - $(ACE_ROOT)/ace/Reactor_Impl.h \ - $(ACE_ROOT)/ace/Svc_Conf_Tokens.h \ - Entity_Manager.i - -.obj/Parser.o .obj/Parser.so .shobj/Parser.o .shobj/Parser.so: Parser.cpp \ - Parser.h \ - $(ACE_ROOT)/ace/pre.h \ - Parser_export.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - $(ACE_ROOT)/ACEXML/common/XMLReader.h \ - $(ACE_ROOT)/ACEXML/common/ACEXML_Export.h \ - $(ACE_ROOT)/ACEXML/common/ContentHandler.h \ - $(ACE_ROOT)/ACEXML/common/Env.h \ - $(ACE_ROOT)/ACEXML/common/XML_Macros.h \ - $(ACE_ROOT)/ace/Exception_Macros.h \ - $(ACE_ROOT)/ACEXML/common/Exception.h \ - $(ACE_ROOT)/ACEXML/common/XML_Types.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h \ - $(ACE_ROOT)/ace/Trace.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - $(ACE_ROOT)/ace/SString.i \ - $(ACE_ROOT)/ACEXML/common/Exception.i \ - $(ACE_ROOT)/ACEXML/common/Env.i \ - $(ACE_ROOT)/ACEXML/common/SAXExceptions.h \ - $(ACE_ROOT)/ACEXML/common/SAXExceptions.i \ - $(ACE_ROOT)/ACEXML/common/Locator.h \ - $(ACE_ROOT)/ACEXML/common/Attributes.h \ - $(ACE_ROOT)/ACEXML/common/DTDHandler.h \ - $(ACE_ROOT)/ACEXML/common/EntityResolver.h \ - $(ACE_ROOT)/ACEXML/common/InputSource.h \ - $(ACE_ROOT)/ACEXML/common/CharStream.h \ - $(ACE_ROOT)/ACEXML/common/ErrorHandler.h \ - $(ACE_ROOT)/ACEXML/common/LocatorImpl.h \ - $(ACE_ROOT)/ACEXML/common/LocatorImpl.i \ - $(ACE_ROOT)/ACEXML/common/NamespaceSupport.h \ - $(ACE_ROOT)/ace/Functor.h \ - $(ACE_ROOT)/ace/Functor.i \ - $(ACE_ROOT)/ace/Functor_T.h \ - $(ACE_ROOT)/ace/Functor_T.i \ - $(ACE_ROOT)/ace/Functor_T.cpp \ - $(ACE_ROOT)/ace/Hash_Map_Manager.h \ - $(ACE_ROOT)/ace/Hash_Map_Manager_T.h \ - $(ACE_ROOT)/ace/Hash_Map_Manager_T.i \ - $(ACE_ROOT)/ace/Hash_Map_Manager_T.cpp \ - $(ACE_ROOT)/ace/Service_Config.h \ - $(ACE_ROOT)/ace/Unbounded_Queue.h \ - $(ACE_ROOT)/ace/Unbounded_Queue.inl \ - $(ACE_ROOT)/ace/Unbounded_Queue.cpp \ - $(ACE_ROOT)/ace/XML_Svc_Conf.h \ - $(ACE_ROOT)/ace/Service_Config.i \ - $(ACE_ROOT)/ace/Reactor.h \ - $(ACE_ROOT)/ace/Handle_Set.h \ - $(ACE_ROOT)/ace/Handle_Set.i \ - $(ACE_ROOT)/ace/Timer_Queue.h \ - $(ACE_ROOT)/ace/Timer_Queue_T.h \ - $(ACE_ROOT)/ace/Test_and_Set.h \ - $(ACE_ROOT)/ace/Test_and_Set.i \ - $(ACE_ROOT)/ace/Test_and_Set.cpp \ - $(ACE_ROOT)/ace/Timer_Queue_T.i \ - $(ACE_ROOT)/ace/Timer_Queue_T.cpp \ - $(ACE_ROOT)/ace/Reactor.i \ - $(ACE_ROOT)/ace/Reactor_Impl.h \ - $(ACE_ROOT)/ace/Svc_Conf_Tokens.h \ - $(ACE_ROOT)/ace/Containers_T.h \ - $(ACE_ROOT)/ace/Containers.h \ - $(ACE_ROOT)/ace/Containers.i \ - $(ACE_ROOT)/ace/Array_Base.h \ - $(ACE_ROOT)/ace/Array_Base.inl \ - $(ACE_ROOT)/ace/Array_Base.cpp \ - $(ACE_ROOT)/ace/Containers_T.i \ - $(ACE_ROOT)/ace/Containers_T.cpp \ - $(ACE_ROOT)/ACEXML/common/NamespaceSupport.i \ - $(ACE_ROOT)/ace/Obstack.h \ - $(ACE_ROOT)/ace/Obstack_T.h \ - $(ACE_ROOT)/ace/Obchunk.h \ - $(ACE_ROOT)/ace/Obchunk.i \ - $(ACE_ROOT)/ace/Obstack_T.i \ - $(ACE_ROOT)/ace/Obstack_T.cpp \ - Entity_Manager.h \ - Entity_Manager.i \ - Parser.i \ - $(ACE_ROOT)/ACEXML/common/Transcode.h \ - $(ACE_ROOT)/ACEXML/common/Transcode.i \ - $(ACE_ROOT)/ACEXML/common/AttributesImpl.h \ - $(ACE_ROOT)/ACEXML/common/AttributesImpl.i - -# IF YOU PUT ANYTHING HERE IT WILL GO AWAY diff --git a/ACEXML/parser/parser/Makefile.ACEXML_Parser b/ACEXML/parser/parser/Makefile.ACEXML_Parser new file mode 100644 index 00000000000..b5331fb3d39 --- /dev/null +++ b/ACEXML/parser/parser/Makefile.ACEXML_Parser @@ -0,0 +1,61 @@ +#---------------------------------------------------------------------------- +# GNU Makefile +#---------------------------------------------------------------------------- +MAKEFILE = Makefile.ACEXML_Parser +DEPENDENCY_FILE = .depend.Makefile.ACEXML_Parser +LIB_UNCHECKED = libACEXML_Parser.a +SHLIB_UNCHECKED = libACEXML_Parser.$(SOEXT) + + + +FILES = \ + Parser \ + Entity_Manager \ + ParserContext \ + ParserInternals +#---------------------------------------------------------------------------- +# Include macros and targets +#---------------------------------------------------------------------------- + +LIB = $(LIB_UNCHECKED) +SHLIB = $(SHLIB_UNCHECKED) + +include $(ACE_ROOT)/include/makeinclude/wrapper_macros.GNU +LSRC = $(addsuffix .cpp, $(FILES)) +ACELIB = -lACE + +include $(ACE_ROOT)/include/makeinclude/macros.GNU +include $(ACE_ROOT)/include/makeinclude/rules.common.GNU +include $(ACE_ROOT)/include/makeinclude/rules.nonested.GNU +include $(ACE_ROOT)/include/makeinclude/rules.lib.GNU +include $(ACE_ROOT)/include/makeinclude/rules.local.GNU + +CPPFLAGS += -I../../.. + + +ifeq ($(shared_libs),1) + ifneq ($(SHLIB),) + CPPFLAGS += -DACEXML_PARSER_BUILD_DLL + endif +endif +ifeq ($(static_libs),1) + ifneq ($(LIB),) + CPPFLAGS += -DACE_AS_STATIC_LIBS + endif +endif + + +LDFLAGS += -L../../../ACEXML/common -L../../../ace + + + +ACE_SHLIBS = -lACEXML $(ACELIB) +#---------------------------------------------------------------------------- +# Local targets +#---------------------------------------------------------------------------- + +realclean: clean +ifneq ($(GENERATED_DIRTY),) + -$(RM) -r $(GENERATED_DIRTY) +endif + diff --git a/ACEXML/parser/parser/Makefile.ACEXML_Parser.bor b/ACEXML/parser/parser/Makefile.ACEXML_Parser.bor new file mode 100644 index 00000000000..bfa3a27d1a8 --- /dev/null +++ b/ACEXML/parser/parser/Makefile.ACEXML_Parser.bor @@ -0,0 +1,59 @@ +# Makefile for building the ACEXML_Parser library with Borland C++ Builder + +NAME = ACEXML_Parser + +NAME = ACEXML_Parser + + +OBJFILES = \ + $(OBJDIR)\Entity_Manager.obj \ + $(OBJDIR)\Parser.obj \ + $(OBJDIR)\ParserContext.obj \ + $(OBJDIR)\ParserInternals.obj + +EXTERNAL_LIBS = \ + \ + +LFLAGS = \ + -j..\..\..\ACEXML\common\$(CONFIG_SUBDIR) -j..\..\..\ACEXML\common \ + -L..\..\..\ACEXML\common\$(CONFIG_SUBDIR) -L..\..\..\ACEXML\common \ + -j..\..\..\ace\$(CONFIG_SUBDIR) -j..\..\..\ace \ + -L..\..\..\ace\$(CONFIG_SUBDIR) -L..\..\..\ace \ + -j$(CORE_BINDIR) \ + -L$(CORE_BINDIR) + +LIBFILES = \ + ACEXML$(LIB_DECORATOR).lib \ + ACE$(LIB_DECORATOR).lib \ + $(EXTERNAL_LIBS) + + + +!ifdef STATIC +LIB_FLAGS = -DACE_AS_STATIC_LIBS +DLL_FLAGS = +!else +LIB_FLAGS = +DLL_FLAGS = -DACEXML_PARSER_BUILD_DLL +!endif + +CFLAGS = \ + -I..\..\.. \ + $(LIB_FLAGS) \ + $(DLL_FLAGS) + +CPPDIR = . + +INCLUDES = \ + Entity_Manager.h \ + Parser.h \ + ParserContext.h \ + ParserInternals.h \ + Parser_export.h \ + Entity_Manager.i \ + Parser.i \ + ParserContext.inl + +BASE_BINDIR = ..\..\..\bin + +!include <$(ACE_ROOT)\include\makeinclude\build_library.bor> diff --git a/ACEXML/parser/parser/Makefile.Parser b/ACEXML/parser/parser/Makefile.Parser new file mode 100644 index 00000000000..0986826a655 --- /dev/null +++ b/ACEXML/parser/parser/Makefile.Parser @@ -0,0 +1,55 @@ +#---------------------------------------------------------------------------- +# GNU Makefile +#---------------------------------------------------------------------------- +MAKEFILE = Makefile.Parser +DEPENDENCY_FILE = .depend.Makefile.Parser +LIB_UNCHECKED = libACEXML_Parser.a +SHLIB_UNCHECKED = libACEXML_Parser.$(SOEXT) + + + +FILES = \ + Parser \ + Entity_Manager \ + ParserContext \ + ParserInternals +#---------------------------------------------------------------------------- +# Include macros and targets +#---------------------------------------------------------------------------- + +LIB = $(LIB_UNCHECKED) +SHLIB = $(SHLIB_UNCHECKED) + +include $(ACE_ROOT)/include/makeinclude/wrapper_macros.GNU +LSRC = $(addsuffix .cpp, $(FILES)) +ACELIB = -lACE + +include $(ACE_ROOT)/include/makeinclude/macros.GNU +include $(ACE_ROOT)/include/makeinclude/rules.common.GNU +include $(ACE_ROOT)/include/makeinclude/rules.nonested.GNU +include $(ACE_ROOT)/include/makeinclude/rules.lib.GNU +include $(ACE_ROOT)/include/makeinclude/rules.local.GNU + +CPPFLAGS += -I../../.. +ifeq ($(shared_libs),1) + ifneq ($(SHLIB),) + CPPFLAGS += -DACEXML_PARSER_BUILD + endif +endif +ifeq ($(static_libs),1) + ifneq ($(LIB),) + CPPFLAGS += -DACE_AS_STATIC_LIBS + endif +endif + + +LDFLAGS += -L../../../ace + +ACE_SHLIBS = -lACEXML $(ACELIB) + +#---------------------------------------------------------------------------- +# Local targets +#---------------------------------------------------------------------------- + +realclean: clean + diff --git a/ACEXML/parser/parser/Makefile.bor b/ACEXML/parser/parser/Makefile.bor index 04603884700..067cbee6d7d 100644 --- a/ACEXML/parser/parser/Makefile.bor +++ b/ACEXML/parser/parser/Makefile.bor @@ -1,20 +1,20 @@ -# Makefile for building the parser +#---------------------------------------------------------------------------- +# Borland Workspace +#---------------------------------------------------------------------------- -NAME = ACEXML_Parser +!include <$(ACE_ROOT)\include\makeinclude\make_flags.bor> -OBJFILES = \ - $(OBJDIR)\Parser.obj \ - $(OBJDIR)\Entity_Manager.obj +all: + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ACEXML_Parser.bor all -CFLAGS = \ - $(ACE_CFLAGS) \ - $(ACE_XML_CFLAGS) \ - -DACEXML_PARSER_BUILD_DLL +clean: + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ACEXML_Parser.bor clean -CPPDIR = .;.. +realclean: + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ACEXML_Parser.bor realclean -LIBFILES = \ - $(ACE_LIB) \ - $(ACE_XML_LIB) +install: + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ACEXML_Parser.bor install -!include <$(ACE_ROOT)\include\makeinclude\build_core_library.bor> +regenerate: + D:\Perl\bin\perl.exe D:\ACE_wrappers\bin\mwc.pl -type borland -recurse diff --git a/ACEXML/parser/parser/Parser.cpp b/ACEXML/parser/parser/Parser.cpp index d3a0b80d1bb..59147b2e655 100644 --- a/ACEXML/parser/parser/Parser.cpp +++ b/ACEXML/parser/parser/Parser.cpp @@ -1,37 +1,50 @@ // $Id$ -#include "ACEXML/parser/parser/Parser.h" +#include "ace/ACE.h" #include "ACEXML/common/Transcode.h" #include "ACEXML/common/AttributesImpl.h" -#include "ace/ACE.h" +#include "ACEXML/common/StrCharStream.h" +#include "ACEXML/common/StreamFactory.h" +#include "ACEXML/parser/parser/Parser.h" +#include "ACEXML/parser/parser/ParserInternals.h" + +#if !defined (__ACEXML_INLINE__) +# include "ACEXML/parser/parser/Parser.i" +#endif /* __ACEXML_INLINE__ */ -static const ACEXML_Char default_attribute_type[] = {'C', 'D', 'A', 'T', 'A', 0}; +static const ACEXML_Char default_attribute_type[] = ACE_TEXT ("CDATA"); static const ACEXML_Char empty_string[] = { 0 }; const ACEXML_Char -ACEXML_Parser::simple_parsing_feature_[] = { 'S', 'i', 'm', 'p', 'l', 'e', 0 }; +ACEXML_Parser::simple_parsing_feature_[] = ACE_TEXT ("Simple"); const ACEXML_Char -ACEXML_Parser::namespaces_feature_[] = {'h', 't', 't', 'p', ':', '/', '/', 'x', 'm', 'l', '.', 'o', 'r', 'g', '/', 's', 'a', 'x', '/', 'f', 'e', 'a', 't', 'u', 'r', 'e', 's', '/', 'n', 'a', 'm', 'e', 's', 'p', 'a', 'c', 'e', 's', 0 }; +ACEXML_Parser::namespaces_feature_[] = ACE_TEXT ("http://xml.org/sax/features/namespaces"); const ACEXML_Char -ACEXML_Parser::namespace_prefixes_feature_[] = {'h', 't', 't', 'p', ':', '/', '/', 'x', 'm', 'l', '.', 'o', 'r', 'g', '/', 's', 'a', 'x', '/', 'f', 'e', 'a', 't', 'u', 'r', 'e', 's', '/', 'n', 'a', 'm', 'e', 's', 'p', 'a', 'c', 'e', '-', 'p', 'r', 'e', 'f', 'i', 'x', 'e', 's', 0 }; +ACEXML_Parser::namespace_prefixes_feature_[] = ACE_TEXT ("http://xml.org/sax/features/namespace-prefixes"); -#if !defined (__ACEXML_INLINE__) -# include "ACEXML/parser/parser/Parser.i" -#endif /* __ACEXML_INLINE__ */ +const ACEXML_Char +ACEXML_Parser::validation_feature_[] = ACE_TEXT ("http://xml.org/sax/features/validation"); ACEXML_Parser::ACEXML_Parser (void) : dtd_handler_ (0), entity_resolver_ (0), content_handler_ (0), error_handler_ (0), - instream_ (0), doctype_ (0), - dtd_system_ (0), - dtd_public_ (0), - locator_(), + current_ (0), + alt_stack_ (MAXPATHLEN), + nested_namespace_ (0), + ref_state_ (ACEXML_ParserInt::INVALID), + external_subset_ (0), + external_entity_ (0), + has_pe_refs_ (0), + standalone_ (0), + external_dtd_ (0), + internal_dtd_ (0), simple_parsing_ (0), + validate_ (1), namespaces_(1), namespace_prefixes_ (0) { @@ -42,190 +55,167 @@ ACEXML_Parser::~ACEXML_Parser (void) } int -ACEXML_Parser::getFeature (const ACEXML_Char *name ACEXML_ENV_ARG_DECL) - ACE_THROW_SPEC ((ACEXML_SAXNotRecognizedException, - ACEXML_SAXNotSupportedException)) +ACEXML_Parser::initialize(ACEXML_InputSource* input) { - if (ACE_OS::strcmp (name, - ACEXML_Parser::simple_parsing_feature_) == 0) - { - return this->simple_parsing_; - } - else if (ACE_OS::strcmp (name, - ACEXML_Parser::namespaces_feature_) == 0) + // Initialize namespace support + if (this->xml_namespace_.init() == -1) { - return this->namespaces_; + ACE_ERROR ((LM_ERROR, + ACE_TEXT ("Error initializing namespace support\n"))); + return -1; } - else if (ACE_OS::strcmp (name, - ACEXML_Parser::namespace_prefixes_feature_) == 0) + for (int i = 0; i < 5; ++i) { - return this->namespace_prefixes_; + if (this->predef_entities_.add_entity (ACEXML_ParserInt::predef_ent_[i], + ACEXML_ParserInt::predef_val_[i]) + != 0) + { + ACE_ERROR ((LM_DEBUG, ACE_TEXT ("Error adding entity %s to Manager"), + ACEXML_ParserInt::predef_ent_[i])); + return -1; + } } - - ACEXML_THROW_RETURN (ACEXML_SAXNotRecognizedException (name), -1); + return this->switch_input (input, input->getSystemId()); } - +void +ACEXML_Parser::parse (const ACEXML_Char *systemId ACEXML_ENV_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) +{ + ACEXML_InputSource* input = 0; + ACE_NEW (input, ACEXML_InputSource (systemId)); + this->parse (input ACEXML_ENV_ARG_PARAMETER); +} void -ACEXML_Parser::setFeature (const ACEXML_Char *name, - int boolean_value ACEXML_ENV_ARG_DECL) - ACE_THROW_SPEC ((ACEXML_SAXNotRecognizedException, - ACEXML_SAXNotSupportedException)) +ACEXML_Parser::parse (ACEXML_InputSource *input ACEXML_ENV_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) { - if (ACE_OS::strcmp (name, - ACEXML_Parser::simple_parsing_feature_) == 0) + if (input == 0) { - this->simple_parsing_ = (boolean_value == 0 ? 0 : 1); - return; + this->fatal_error(ACE_TEXT ("Invalid input source") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK; } - else if (ACE_OS::strcmp (name, - ACEXML_Parser::namespaces_feature_) == 0) + if (this->content_handler_ == 0) { - this->namespaces_ = (boolean_value == 0 ? 0 : 1); - return; + this->fatal_error (ACE_TEXT ("No content handlers defined. Exiting..") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK; } - else if (ACE_OS::strcmp (name, - ACEXML_Parser::namespace_prefixes_feature_) == 0) + + if (this->validate_ && this->dtd_handler_ == 0) { - this->namespace_prefixes_ = (boolean_value == 0 ? 0 : 1); - return; + this->fatal_error (ACE_TEXT ("No DTD handlers defined. Exiting..") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK; } - ACEXML_THROW (ACEXML_SAXNotRecognizedException (name)); -} - -void * -ACEXML_Parser::getProperty (const ACEXML_Char *name ACEXML_ENV_ARG_DECL) - ACE_THROW_SPEC ((ACEXML_SAXNotRecognizedException, - ACEXML_SAXNotSupportedException)) -{ - ACEXML_THROW_RETURN (ACEXML_SAXNotSupportedException (name), 0); -} -void -ACEXML_Parser::setProperty (const ACEXML_Char *name, - void *value ACEXML_ENV_ARG_DECL) - ACE_THROW_SPEC ((ACEXML_SAXNotRecognizedException, - ACEXML_SAXNotSupportedException)) -{ - ACE_UNUSED_ARG (value); - - ACEXML_THROW (ACEXML_SAXNotSupportedException (name)); -} - -void -ACEXML_Parser::report_error (const ACEXML_Char* message ACEXML_ENV_ARG_DECL) -{ - ACEXML_SAXParseException* exception = 0; - ACE_NEW_NORETURN (exception, - ACEXML_SAXParseException (message)); - if (this->error_handler_) - this->error_handler_->error (*exception ACEXML_ENV_ARG_PARAMETER); - else - ACEXML_ENV_RAISE (exception); - return; -} - -void -ACEXML_Parser::report_warning (const ACEXML_Char* message ACEXML_ENV_ARG_DECL) -{ - ACEXML_SAXParseException* exception = 0; - ACE_NEW_NORETURN (exception, - ACEXML_SAXParseException (message)); - if (this->error_handler_) - this->error_handler_->warning (*exception ACEXML_ENV_ARG_PARAMETER); - return; -} - -void -ACEXML_Parser::report_fatal_error (const ACEXML_Char* message ACEXML_ENV_ARG_DECL) -{ - ACEXML_SAXParseException* exception = 0; - ACE_NEW_NORETURN (exception, - ACEXML_SAXParseException (message)); - if (this->error_handler_) - this->error_handler_->fatalError (*exception ACEXML_ENV_ARG_PARAMETER); - ACEXML_ENV_RAISE (exception); - return; -} - -void -ACEXML_Parser::parse (ACEXML_InputSource *input ACEXML_ENV_ARG_DECL) - ACE_THROW_SPEC ((ACEXML_SAXException)) -{ - if (input == 0 || (this->instream_ = input->getCharStream ()) == 0) + if (this->initialize(input) == -1) { - this->report_fatal_error(ACE_TEXT ("Invalid input source") ACEXML_ENV_ARG_PARAMETER); - return; + this->fatal_error (ACE_TEXT ("Failed to initialize parser state") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK; } + // Set up Locator. + this->content_handler_->setDocumentLocator (this->current_->getLocator()); - // Set up Locator. At this point, the systemId and publicId are null. We - // can't do better, as we don't know anything about the InputSource - // currently, and according to the SAX spec, the parser should set up the - // locator before reporting any document events. - if (this->content_handler_) - this->content_handler_->setDocumentLocator (&this->locator_); - - if (this->simple_parsing_ == 0) + int xmldecl_defined = 0; + ACEXML_Char fwd = this->get(); // Consume '<' + if (fwd == '<' && this->peek() == '?') { - this->parse_xml_prolog (ACEXML_ENV_SINGLE_ARG_PARAMETER); + this->get(); // Consume '?' + fwd = this->peek(); + if (fwd == 'x' && !xmldecl_defined) + { + this->parse_xml_decl (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK; + xmldecl_defined = 1; + } + } + // We need a XMLDecl in a Valid XML document + if (this->validate_ && !xmldecl_defined) + { + this->fatal_error (ACE_TEXT ("Expecting an XMLDecl at the beginning of") + ACE_TEXT (" a valid document") + ACEXML_ENV_ARG_PARAMETER); ACEXML_CHECK; } - this->content_handler_->startDocument (ACEXML_ENV_SINGLE_ARG_PARAMETER); ACEXML_CHECK; int doctype_defined = 0; - for (int prolog_done = 0; prolog_done == 0; ) { - if (this->skip_whitespace (0) != '<') - { - this->report_fatal_error (ACE_TEXT ("Expecting '<'") ACEXML_ENV_ARG_PARAMETER); - return; - } - ACEXML_Char fwd = this->peek (); - switch (fwd) + // Expect a '<' only if we have encountered a XMLDecl, or we are + // looping through Misc blocks. + if (xmldecl_defined) { - case '!': - this->get (); // consume the '!' - fwd = this->peek (); - if (fwd == 'D' && !doctype_defined) // DOCTYPE + if (this->skip_whitespace () != '<') { - // This will also take care of the trailing MISC block if any. - this->parse_doctypedecl (ACEXML_ENV_SINGLE_ARG_PARAMETER); + this->fatal_error (ACE_TEXT ("Expecting '<' at the beginning of ") + ACE_TEXT ("Misc section") + ACEXML_ENV_ARG_PARAMETER); ACEXML_CHECK; - doctype_defined = 1; - break; - } - else if (fwd == '-') // COMMENT - { - if (this->grok_comment () < 0) - { - this->report_fatal_error(ACE_TEXT ("Invalid comment") ACEXML_ENV_ARG_PARAMETER); - return; - } } - else - { - this->report_fatal_error (ACE_TEXT ("Duplicate DOCTYPE definitions") ACEXML_ENV_ARG_PARAMETER); - return; - } - break; - case '?': - this->parse_processing_instruction (ACEXML_ENV_SINGLE_ARG_PARAMETER); - ACEXML_CHECK; - break; - case 0: - this->report_fatal_error (ACE_TEXT ("Unexpected EOF") ACEXML_ENV_ARG_PARAMETER); - return; - default: // Root element begins - prolog_done = 1; - break; + fwd = this->peek(); + } + switch (fwd) + { + case '?': + this->get(); + this->parse_processing_instruction (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK; + xmldecl_defined = 1; + break; + case '!': + this->get(); + fwd = this->peek (); + if (fwd == 'D' && !doctype_defined) // DOCTYPE + { + // This will also take care of the trailing MISC block if any. + this->parse_doctypedecl (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK; + doctype_defined = 1; + // Now that we have a DOCTYPE Decl defined, we shouldn't + // accept XML Decl any longer + xmldecl_defined = 1; + } + else if (fwd == 'D') + { + this->fatal_error (ACE_TEXT ("Duplicate DOCTYPE declaration") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK; + } + else if (fwd == '-') // COMMENT + { + if (this->parse_comment () < 0) + { + this->fatal_error(ACE_TEXT ("Invalid comment in document") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK; + } + xmldecl_defined = 1; + } + break; + case 0: + this->fatal_error (ACE_TEXT ("Unexpected end-of-file") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK; + default: // Root element begins + prolog_done = 1; + break; } } + if (this->validate_ && !doctype_defined) + { + this->warning (ACE_TEXT ("No doctypeDecl in valid document") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK; + } + // Now parse root element. this->parse_element (1 ACEXML_ENV_ARG_PARAMETER); ACEXML_CHECK; @@ -233,932 +223,962 @@ ACEXML_Parser::parse (ACEXML_InputSource *input ACEXML_ENV_ARG_DECL) this->content_handler_->endDocument (ACEXML_ENV_SINGLE_ARG_PARAMETER); ACEXML_CHECK; - // Reset the Locator held within the parser - this->locator_.reset(); -} + // Reset the parser state + this->reset(); -void -ACEXML_Parser::parse (const ACEXML_Char *systemId ACEXML_ENV_ARG_DECL) - ACE_THROW_SPEC ((ACEXML_SAXException)) -{ - // @@ Not implemented. - ACE_UNUSED_ARG (systemId); - - ACEXML_THROW (ACEXML_SAXNotSupportedException ()); } - -void -ACEXML_Parser::parse_xml_prolog (ACEXML_ENV_SINGLE_ARG_DECL) - ACE_THROW_SPEC ((ACEXML_SAXException)) +int +ACEXML_Parser::parse_doctypedecl (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) { - if (this->parse_token (ACE_TEXT("<?xml")) < 0) + if (this->parse_token (ACE_TEXT ("DOCTYPE")) < 0) { - this->report_fatal_error(ACE_TEXT ("Invalid XMLDecl ('<?xml' ?)") ACEXML_ENV_ARG_PARAMETER); - return; + this->fatal_error(ACE_TEXT ("Expecting keyword DOCTYPE in a doctypedecl") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } - ACEXML_Char *astring; + ACEXML_Char nextch = 0; + if (this->skip_whitespace_count (&nextch) == 0) + { + this->fatal_error(ACE_TEXT ("Expecting a space between DOCTYPE keyword ") + ACE_TEXT ("and name") ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } - if (this->skip_whitespace (0) != 'v' // Discard whitespace - || (this->parse_token (ACE_TEXT("ersion")) < 0) - || this->skip_equal () != 0 - || this->get_quoted_string (astring) != 0) + this->doctype_ = this->parse_name (); + if (this->doctype_ == 0) { - this->report_fatal_error (ACE_TEXT ("Unrecognized XMLDecl ('version'?)") ACEXML_ENV_ARG_PARAMETER); - return; + this->fatal_error(ACE_TEXT ("Invalid DOCTYPE name") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } - // @@ Handle version number here. - int xmldecl_state = 0; - int seen_encoding = 0; + int count = this->skip_whitespace_count (&nextch); - while (1) + if (nextch == 'S' || nextch == 'P') // ExternalID defined { - ACEXML_Char fwd = this->peek (); - if (fwd != '?') + if (count == 0) { - fwd = this->skip_whitespace (0); // Discard whitespace - if (fwd == '?') - { - // Fall down to consume the '?' and wrap up the XML Decl parsing. - } - else if (xmldecl_state == 0 && fwd == 'e') - { - 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_TEXT ("Duplicate encoding defined") ACEXML_ENV_ARG_PARAMETER); - return; - } - else - { - seen_encoding = 1; - if (ACE_OS::strcmp (astring, - this->instream_->getEncoding()) != 0) - { - if (ACE_OS::strstr (astring, - this->instream_->getEncoding()) != 0) - { - ACE_ERROR ((LM_ERROR, - ACE_TEXT ("Detected Encoding is %s : Declared Encoding is %s"), - this->instream_->getEncoding(), astring)); - this->report_fatal_error (ACE_TEXT ("Encoding declaration doesn't match detected encoding") ACEXML_ENV_ARG_PARAMETER); - return; - } - } - } - continue; - } - else - break; - } - else if (xmldecl_state < 2 && fwd == 's') - { - 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_TEXT ("yes")) == 0) - { - // @@ This is a standalone XML file. - continue; - } - else if (ACE_OS::strcmp (astring, ACE_TEXT ("no")) == 0) - { - // @@ This is not a stand alone XML file. - continue; - } - } - break; - } - else - break; + this->fatal_error(ACE_TEXT ("Expecting a space between DOCTYPE") + ACE_TEXT ("keyword and name") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } - if (this->parse_token (ACE_TEXT ("?>")) < 0) + this->external_dtd_ = 1; + this->parse_external_dtd (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + + nextch = this->skip_whitespace (); + switch (nextch) + { + case '[': + this->internal_dtd_ = 1; // Internal DTD definition + this->parse_internal_dtd (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); break; - return; - } // End parsing XML Decl. - this->report_fatal_error (ACE_TEXT ("Unrecognized XML Decl ('standalone'?)") ACEXML_ENV_ARG_PARAMETER); - return; + case '>': // End of DTD definition + // This is an XML document without a doctypedecl. + if (this->validate_ && !this->external_dtd_) + { + this->fatal_error (ACE_TEXT ("No DTD defined") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + return 0; + case '0': + this->fatal_error (ACE_TEXT ("Unexpected end-of-file") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + default: + break; + } + + if (this->skip_whitespace() != '>') + { + this->fatal_error(ACE_TEXT ("Expecting '>' at end of doctypedecl") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + return 0; } int -ACEXML_Parser::grok_comment (void) +ACEXML_Parser::parse_internal_dtd (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) { - /// Simply filter out all the comment - int state = 0; + this->ref_state_ = ACEXML_ParserInt::IN_INT_DTD; + ACEXML_Char nextch = this->skip_whitespace (); + do { + switch (nextch) + { + case '<': + nextch = this->get(); + switch (nextch) + { + case '!': + this->parse_markup_decl (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + break; + case '?': + this->parse_processing_instruction (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + break; + default: + this->fatal_error (ACE_TEXT ("Invalid internal subset") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + break; + } + break; + case '%': + this->has_pe_refs_ = 1; + this->parse_PE_reference (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + break; + case ']': // End of internal definitions. + return 0; + case '&': + this->fatal_error (ACE_TEXT ("Invalid Reference in internal DTD") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + break; + case 0: + this->pop_context (0 ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + break; + default: + this->fatal_error (ACE_TEXT ("Invalid content in internal subset") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + }; + nextch = this->skip_whitespace (); + } while (1); - if (this->get () != '-' || // Skip the opening "<!--" - this->get () != '-' || // completely. - this->get () == '-') // and at least something not '-'. - return -1; + ACE_NOTREACHED (return -1); +} - while (state < 3) - // Waiting for the trailing three character '-->'. Notice that - // according to the spec, '--->' is not a valid closing comment - // sequence. But we'll let it pass anyway. +int +ACEXML_Parser::parse_external_dtd (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) +{ + this->ref_state_ = ACEXML_ParserInt::IN_EXT_DTD; + ACEXML_Char* publicId = 0; + ACEXML_Char* systemId = 0; + if (this->parse_external_id (publicId, systemId + ACEXML_ENV_ARG_PARAMETER) != 0) { - ACEXML_Char fwd = this->get (); - if ((fwd == '-' && state < 2) || - (fwd == '>' && state == 2)) - state += 1; + this->fatal_error (ACE_TEXT ("Error in parsing ExternalID") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + if (this->validate_) + { + ACEXML_Char* uri = this->normalize_systemid (systemId); + ACE_Auto_Basic_Array_Ptr<ACEXML_Char> cleanup_uri (uri); + ACEXML_InputSource* ip = 0; + if (this->entity_resolver_) + { + ip = this->entity_resolver_->resolveEntity (publicId, + (uri ? uri : systemId) + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + if (ip) + { + if (this->switch_input (ip, (uri ? uri : systemId), publicId) != 0) + return -1; + } else - state = 0; // Reset parse state. + { + ACEXML_StreamFactory factory; + ACEXML_CharStream* cstream = factory.create_stream (uri ? + uri: systemId); + if (!cstream) { + this->fatal_error (ACE_TEXT ("Invalid input source") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + if (this->switch_input (cstream, systemId, publicId) != 0) + return -1; + } + this->parse_external_subset (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } return 0; } + int -ACEXML_Parser::parse_processing_instruction (ACEXML_ENV_SINGLE_ARG_DECL) +ACEXML_Parser::parse_external_subset (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) { - if (this->get () != '?') - { // How did we get here? - this->report_fatal_error(ACE_TEXT ("Internal error") ACEXML_ENV_ARG_PARAMETER); - return -1; - } - const ACEXML_Char *pitarget = this->read_name (); - ACEXML_Char *instruction = 0; + this->ref_state_ = ACEXML_ParserInt::IN_EXT_DTD; + this->external_subset_ = 1; + int nrelems = 0; + ACEXML_Char nextch = this->skip_whitespace(); + do { + switch (nextch) + { + case '<': + nextch = this->get(); + switch (nextch) + { + case '!': + nextch = this->peek(); + if (nextch == '[') + this->parse_conditional_section (ACEXML_ENV_SINGLE_ARG_PARAMETER); + else + this->parse_markup_decl (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + break; + case '?': + nextch = this->peek(); + if (nextch == 'x') + this->parse_text_decl (ACEXML_ENV_SINGLE_ARG_PARAMETER); + else + this->parse_processing_instruction (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + break; + default: + this->fatal_error (ACE_TEXT ("Invalid content in external DTD") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + break; + case '%': + this->parse_PE_reference (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + break; + case 0: + nrelems = this->pop_context (0 ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + if (nrelems == 1) + return 0; + break; + default: + this->fatal_error (ACE_TEXT ("Invalid content in external DTD") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + nextch = this->skip_whitespace(); + } while (1); +} - if (ACE_OS::strcasecmp (ACE_TEXT ("xml"), pitarget) != 0) +int +ACEXML_Parser::parse_conditional_section (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) +{ + ACEXML_Char ch = this->get (); + if (ch != '[') { - // Invalid PITarget name. - this->report_fatal_error(ACE_TEXT ("PITarget name cannot start with 'xml'") ACEXML_ENV_ARG_PARAMETER); - return -1; + this->fatal_error(ACE_TEXT ("Internal Parser Error") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } - - int state = 0; - ACEXML_Char ch = this->skip_whitespace (0); - - while (state < 2) + if (this->skip_whitespace() != 'I') { - switch (ch) - { - case '?': - if (state == 0) - state = 1; + this->fatal_error (ACE_TEXT ("Invalid conditionalSect") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + ch = this->get(); + int include = 0; + switch (ch) + { + case 'N': + if (this->parse_token (ACE_TEXT ("CLUDE")) < 0) + { + this->fatal_error (ACE_TEXT ("Expecting keyword INCLUDE in ") + ACE_TEXT ("conditionalSect") ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + include = 1; + break; + case 'G': + if (this->parse_token (ACE_TEXT ("GNORE")) < 0) + { + this->fatal_error (ACE_TEXT ("Expecting keyword IGNORE in ") + ACE_TEXT ("conditionalSect") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + include = 0; + break; + default: + this->fatal_error (ACE_TEXT ("Invalid conditionalSect") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + if (this->skip_whitespace() != '[') + { + this->fatal_error (ACE_TEXT ("Expecting '[' in conditionalSect") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + if (include) + this->parse_includesect (ACEXML_ENV_SINGLE_ARG_PARAMETER); + else + this->parse_ignoresect (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + return 0; +} + +int +ACEXML_Parser::parse_ignoresect (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) +{ + ACEXML_Char nextch = this->skip_whitespace(); + int count = 0; + do { + switch (nextch) + { + case '<': + if (this->peek() == '!') + { + this->get(); + if (this->peek() == '[') + { + this->get(); + count++; + } + } break; - case '>': - if (state == 1) + case ']': + if (this->peek() == ']') { - instruction = this->obstack_.freeze (); - this->content_handler_->processingInstruction (pitarget, - instruction ACEXML_ENV_ARG_PARAMETER); - ACEXML_CHECK_RETURN (-1); - this->obstack_.unwind (ACE_const_cast (ACEXML_Char*, pitarget)); - return 0; + this->get(); + if (this->peek() == '>') + { + this->get(); + --count; + } } break; - case 0x0D: // End-of-Line handling - ch = (this->peek () == 0x0A ? this->get () : 0x0A); - // Fall thru... - case 0x0A: - // Fall thru... + case 0: // [VC: Proper Conditional Section/PE Nesting] + if (count != 0) + { + this->fatal_error (ACE_TEXT ("Invalid Conditional Section/PE ") + ACE_TEXT ("Nesting ") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } default: - if (state == 1) - this->obstack_.grow ('?'); - this->obstack_.grow (ch); - state = 0; - } - ch = this->get (); - } - return -1; + break; + } + nextch = this->get(); + } while (1); } int -ACEXML_Parser::parse_doctypedecl (ACEXML_ENV_SINGLE_ARG_DECL) - ACE_THROW_SPEC ((ACEXML_SAXException)) +ACEXML_Parser::parse_includesect (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) { - if (this->parse_token (ACE_TEXT ("DOCTYPE")) < 0) - { - this->report_fatal_error(ACE_TEXT ("Expecting keyword 'DOCTYPE'") ACEXML_ENV_ARG_PARAMETER); - return -1; - } + ACEXML_Char nextch = this->skip_whitespace(); + do { + switch (nextch) + { + case '<': + nextch = this->get(); + switch (nextch) + { + case '!': + nextch = this->peek(); + if (nextch == '[') + this->parse_conditional_section (ACEXML_ENV_SINGLE_ARG_PARAMETER); + else + this->parse_markup_decl (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + break; + case '?': + nextch = this->peek(); + this->parse_processing_instruction (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + break; + default: + this->fatal_error (ACE_TEXT ("Invalid includeSect") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + break; + case '%': + this->parse_PE_reference (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + break; + case 0: // [VC: Proper Conditional Section/PE Nesting] + this->fatal_error (ACE_TEXT ("Invalid Conditional Section/PE ") + ACE_TEXT ("Nesting ") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + case ']': + if (this->peek() == ']') + { + nextch = this->get(); + if (this->peek() == '>') + { + nextch = this->get(); + return 0; + } + } + default: + this->fatal_error (ACE_TEXT ("Invalid includeSect") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + nextch = this->skip_whitespace(); + } while (1); +} - ACEXML_Char nextch = this->skip_whitespace (0); - if (nextch == 0) +int +ACEXML_Parser::parse_markup_decl (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) +{ + ACEXML_Char nextch = this->peek (); + switch (nextch) { - this->report_fatal_error(ACE_TEXT ("Expecting a DOCTYPE name") ACEXML_ENV_ARG_PARAMETER); - return -1; - } + case 'E': // An ELEMENT or ENTITY decl + this->get (); + nextch = this->peek (); + switch (nextch) + { + case 'L': + this->parse_element_decl (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + break; + case 'N': + this->parse_entity_decl (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + break; + default: + this->fatal_error(ACE_TEXT ("Expecting keyword ELEMENT/ENTITY") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + break; - this->doctype_ = this->read_name (nextch); + case 'A': // An ATTLIST decl + this->parse_attlist_decl (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + break; - this->skip_whitespace_count (&nextch); + case 'N': // A NOTATION decl + this->parse_notation_decl (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + break; - if (nextch == 'S' || nextch == 'P') // ExternalID defined - { - this->parse_external_id_and_ref (this->dtd_public_, - this->dtd_system_ - ACEXML_ENV_ARG_PARAMETER); - ACEXML_CHECK_RETURN (-1); -// if (this->dtd_public_ == 0) -// ACE_DEBUG ((LM_DEBUG, -// ACE_TEXT ("ACEXML Parser got external DTD id: SYSTEM %s\n"), -// this->dtd_system_)); -// else -// ACE_DEBUG ((LM_DEBUG, -// ACE_TEXT ("ACEXML Parser got DTD external id: PUBLIC %s %s\n"), -// this->dtd_public_, this->dtd_system_)); + case '-': // a comment. + if (this->parse_comment () < 0) + { + this->fatal_error(ACE_TEXT ("Invalid comment") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + break; + case 0: // [VC: Proper Declaration/PE Nesting] + this->fatal_error (ACE_TEXT ("Unexpected end-of-file") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + default: + this->fatal_error (ACE_TEXT ("Invalid markupDecl") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } + return 0; +} - nextch = this->skip_whitespace (0); +int +ACEXML_Parser::parse_external_id (ACEXML_Char *&publicId, + ACEXML_Char *&systemId + ACEXML_ENV_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) +{ + publicId = systemId = 0; + ACEXML_Char nextch = this->get (); + ACEXML_Char fwd = 0; switch (nextch) { - case '[': // Internal DTD definition - if (this->parse_internal_dtd (ACEXML_ENV_SINGLE_ARG_PARAMETER) < 0) - return -1; // Error in markupdecl - break; - case '>': // End of DTD definition - // this is an XML document without a dectypedecl. - return 0; - case '0': - this->report_fatal_error (ACE_TEXT ("Unexpected EOF") ACEXML_ENV_ARG_PARAMETER); - return -1; - default: - break; + case 'S': // External SYSTEM id. + if (this->parse_token (ACE_TEXT ("YSTEM")) < 0 || + this->skip_whitespace_count () < 1) + { + this->fatal_error(ACE_TEXT ("Expecting keyword SYSTEM") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + if (this->parse_system_literal (systemId) != 0) + { + this->fatal_error(ACE_TEXT ("Invalid systemLiteral") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + break; + case 'P': // External PUBLIC id or previously defined PUBLIC id. + if (this->parse_token (ACE_TEXT ("UBLIC")) < 0 || + this->skip_whitespace_count () < 1) + { + this->fatal_error(ACE_TEXT ("Expecing keyword PUBLIC") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + if (this->parse_pubid_literal (publicId) != 0) + { + this->fatal_error(ACE_TEXT ("Invalid PubidLiteral") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + this->skip_whitespace_count(&fwd); + if (fwd == '\'' || fwd == '"') + { + if (this->parse_system_literal (systemId) != 0) + { + this->fatal_error(ACE_TEXT ("Invalid systemLiteral") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + } + else if (this->ref_state_ != ACEXML_ParserInt::IN_NOTATION) + { + this->fatal_error(ACE_TEXT ("Expecting systemLiteral after a ") + ACE_TEXT ("PUBLIC keyword") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + break; + default: + this->fatal_error(ACE_TEXT ("Invalid system/public Literal") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } + return 0; +} - if (this->skip_whitespace (0) != '>') +ACEXML_Char* +ACEXML_Parser::normalize_systemid (const ACEXML_Char* systemId) +{ + if (ACE_OS::strstr (systemId, ACE_TEXT("ftp://")) != 0 || + ACE_OS::strstr (systemId, ACE_TEXT ("http://")) != 0 || + ACE_OS::strstr (systemId, ACE_TEXT ("file://")) != 0) + return 0; + else { - this->report_fatal_error(ACE_TEXT ("Internal error") ACEXML_ENV_ARG_PARAMETER); - return -1; + ACEXML_Char* normalized_uri = 0; + const ACEXML_Char* baseURI = this->current_->getLocator()->getSystemId(); + ACE_ASSERT (baseURI); + const ACEXML_Char* temp = 0; + if (ACE_OS::strstr (baseURI, ACE_TEXT ("http://")) != 0) + // baseURI is a HTTP URL and systemId is relative. Note that this + // is not compliant with RFC2396. Caveat Emptor ! + temp = ACE_OS::strrchr (baseURI, '/'); + else + // baseURI is a local file and systemId is relative + // Unlike the HTTP one, this will work always. + temp = ACE_OS::strrchr (baseURI,ACE_DIRECTORY_SEPARATOR_CHAR); + if (temp) + { + size_t pos = temp - baseURI + 1; + size_t len = pos + ACE_OS::strlen (systemId) + 1; + ACE_NEW_RETURN (normalized_uri, ACEXML_Char[len], 0); + ACE_OS::strncpy (normalized_uri, baseURI, pos); + ACE_OS::strcpy (normalized_uri + pos, systemId); + return normalized_uri; + } + return 0; } - return 0; } void ACEXML_Parser::parse_element (int is_root ACEXML_ENV_ARG_DECL) - ACE_THROW_SPEC ((ACEXML_SAXException)) + ACE_THROW_SPEC ((ACEXML_SAXException)) { // Parse STag. - const ACEXML_Char *startname = this->read_name (); + const ACEXML_Char *startname = this->parse_name (); if (startname == 0) { - this->report_fatal_error (ACE_TEXT ("Unexpected EOF") ACEXML_ENV_ARG_PARAMETER); + this->fatal_error (ACE_TEXT ("Unexpected end-of-file") + ACEXML_ENV_ARG_PARAMETER); return; } if (is_root && this->doctype_ != 0 && ACE_OS::strcmp (startname, this->doctype_) != 0) { - this->report_fatal_error (ACE_TEXT ("Root element missing") ACEXML_ENV_ARG_PARAMETER); - return; + this->fatal_error (ACE_TEXT ("Root element different from DOCTYPE") + ACEXML_ENV_ARG_PARAMETER); + return ; } ACEXML_AttributesImpl attributes; ACEXML_Char ch; - int new_namespace = 0; - const ACEXML_Char *endname = 0; - const ACEXML_Char *ns_uri, *ns_lname; // namespace URI and localName - ACEXML_Char* prefix = 0; - ACEXML_Char* name = 0; + const ACEXML_Char* ns_uri = 0; + const ACEXML_Char* ns_lname = 0; // namespace URI and localName for (int start_element_done = 0; start_element_done == 0;) { - ch = this->skip_whitespace (0); + ch = this->skip_whitespace (); switch (ch) { - case 0: - this->report_fatal_error(ACE_TEXT ("Internal error") ACEXML_ENV_ARG_PARAMETER); - return; - case '/': - if (this->get () != '>') - { - this->report_fatal_error(ACE_TEXT ("Expecting '>'") ACEXML_ENV_ARG_PARAMETER); - return; - } - else - { - this->xml_namespace_.processName(startname, ns_uri, ns_lname, 0); - prefix = ACE_const_cast (ACEXML_Char*, - this->xml_namespace_.getPrefix(ns_uri)); - this->report_prefix_mapping (prefix, ns_uri, ns_lname, 1 ACEXML_ENV_ARG_PARAMETER); - ACEXML_CHECK; - this->content_handler_->startElement (ns_uri, ns_lname, - startname, &attributes ACEXML_ENV_ARG_PARAMETER); - ACEXML_CHECK; - this->content_handler_->endElement (ns_uri, ns_lname, startname ACEXML_ENV_ARG_PARAMETER); - ACEXML_CHECK; - this->report_prefix_mapping (prefix, ns_uri, ns_lname, 0 ACEXML_ENV_ARG_PARAMETER); - ACEXML_CHECK; - } - if (new_namespace != 0) - this->xml_namespace_.popContext (); - return; - - case '>': - { - this->xml_namespace_.processName (startname, ns_uri, ns_lname, 0); - prefix = ACE_const_cast (ACEXML_Char*, - this->xml_namespace_.getPrefix (ns_uri)); - this->report_prefix_mapping (prefix, ns_uri, ns_lname, 1 ACEXML_ENV_ARG_PARAMETER); + case 0: + this->fatal_error(ACE_TEXT ("Internal Parser error") + ACEXML_ENV_ARG_PARAMETER); + return; + case '/': + if (this->get () != '>') + { + this->fatal_error(ACE_TEXT ("Expecting '>' at end of element ") + ACE_TEXT ("definition") + ACEXML_ENV_ARG_PARAMETER); + return; + } + this->xml_namespace_.processName(startname, ns_uri, + ns_lname, 0); + this->prefix_mapping (this->xml_namespace_.getPrefix(ns_uri), + ns_uri, ns_lname, 1 + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK; + this->content_handler_->startElement(ns_uri, ns_lname, + startname, &attributes + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK; + this->content_handler_->endElement (ns_uri, ns_lname, startname + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK; + this->prefix_mapping (this->xml_namespace_.getPrefix(ns_uri), + ns_uri, ns_lname, 0 + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK; + if (this->nested_namespace_ >= 1) + { + this->xml_namespace_.popContext (); + this->nested_namespace_--; + } + return; + case '>': + this->xml_namespace_.processName (startname, ns_uri, + ns_lname, 0); + this->prefix_mapping (this->xml_namespace_.getPrefix(ns_uri), + ns_uri, ns_lname, 1 + ACEXML_ENV_ARG_PARAMETER); ACEXML_CHECK; - this->content_handler_->startElement (ns_uri, ns_lname, startname, - &attributes ACEXML_ENV_ARG_PARAMETER); + this->content_handler_->startElement(ns_uri, ns_lname, startname, + &attributes + ACEXML_ENV_ARG_PARAMETER); ACEXML_CHECK; start_element_done = 1; break; - } - default: - ACEXML_Char *attvalue = 0; - ACEXML_Char *attname = this->read_name (ch); - - if (attname == 0 || - this->skip_equal () != 0 || - this->get_quoted_string (attvalue) != 0) - { - this->report_fatal_error(ACE_TEXT ("Error reading attribute") ACEXML_ENV_ARG_PARAMETER); - return; - } - - // Handling new namespace if any. Notice that the order of - // namespace declaration does matter. - if (ACE_OS::strncmp (attname, ACE_TEXT("xmlns"), 5) == 0) - { - if (this->namespaces_) - { - if (new_namespace == 0) - { - this->xml_namespace_.pushContext (); - new_namespace = 1; - } - name = ACE_OS::strchr (attname, ':'); - const ACEXML_Char* ns_name = (name == 0)?empty_string:name+1; - if (this->xml_namespace_.declarePrefix (ns_name, - attvalue) == -1) - { - this->report_fatal_error(ACE_TEXT ("Duplicate namespace prefix") ACEXML_ENV_ARG_PARAMETER); - return; - } - } - if (this->namespace_prefixes_) - { - // Namespace_prefixes_feature_ is required. So add the - // xmlns:foo to the list of attributes. - if (attributes.addAttribute (0, 0, attname, - default_attribute_type, - attvalue) == -1) - { - this->report_fatal_error(ACE_TEXT ("Duplicate attribute found") ACEXML_ENV_ARG_PARAMETER); - return; - } - } - if (!this->namespaces_ && !this->namespace_prefixes_) - { - this->report_fatal_error(ACE_TEXT ("Both namespaces feature and namespace_prefixes feature are false. Illegal Mode") ACEXML_ENV_ARG_PARAMETER); - return; - } - } - else - { - const ACEXML_Char *uri, *lName; - this->xml_namespace_.processName (attname, uri, lName, 1); - if (attributes.addAttribute (uri, lName, attname, - default_attribute_type, - attvalue) == -1) - { - this->report_fatal_error(ACE_TEXT ("Duplicate attribute found") ACEXML_ENV_ARG_PARAMETER); - return; - } - } - break; - } - } - ACEXML_Char *cdata; - size_t cdata_length = 0; - - // Parse element contents. - while (1) - { - ACEXML_Char ch = this->get (); + default: + ACEXML_Char *attvalue = 0; + ACEXML_Char *attname = this->parse_name (ch); - switch (ch) - { - case 0: - this->report_fatal_error(ACE_TEXT ("Internal error") ACEXML_ENV_ARG_PARAMETER); - return; - case '<': - // Push out old 'characters' event. - if (cdata_length != 0) - { - cdata = this->obstack_.freeze (); - this->content_handler_->characters (cdata, 0, - ACE_static_cast (int, cdata_length) - ACEXML_ENV_ARG_PARAMETER); - ACEXML_CHECK; - this->obstack_.unwind (cdata); - cdata_length = 0; - } + if (attname == 0 || + this->skip_equal () != 0 || + this->parse_attvalue (attvalue ACEXML_ENV_ARG_PARAMETER) != 0) + { + this->fatal_error(ACE_TEXT ("Error reading attribute value") + ACEXML_ENV_ARG_PARAMETER); + return; + } - switch (this->peek ()) - { - case '!': // a comment or a CDATA section. - this->get (); // consume '!' - ch = this->peek (); - if (ch == '-') // a comment - { - if (this->grok_comment () < 0) - { - this->report_fatal_error(ACE_TEXT ("Error parsing comment") ACEXML_ENV_ARG_PARAMETER); - return; - } - } - else if (ch == '[') // a CDATA section. - { - this->parse_cdata (ACEXML_ENV_SINGLE_ARG_PARAMETER); - ACEXML_CHECK; - } - else - { - this->report_fatal_error(ACE_TEXT ("Unexpected character") ACEXML_ENV_ARG_PARAMETER); - return; - } - break; - case '?': // a PI. - this->parse_processing_instruction (ACEXML_ENV_SINGLE_ARG_PARAMETER); - ACEXML_CHECK; - break; - case '/': // an ETag. + // Handling new namespace if any. Notice that the order of + // namespace declaration does matter. + if (ACE_OS::strcmp (attname, ACE_TEXT("xmlns")) == 0) { - this->get (); // consume '/' - endname = this->read_name (); - if (endname == 0 || - ACE_OS::strcmp (startname, endname) != 0) + if (this->namespaces_) { - this->report_fatal_error(ACE_TEXT ("Mismatched End-tag encountered") ACEXML_ENV_ARG_PARAMETER); - return ; + this->xml_namespace_.pushContext (); + this->nested_namespace_++; + ACEXML_Char* name = ACE_OS::strchr (attname, ':'); + const ACEXML_Char* ns_name = (name == 0)? + empty_string:name+1; + if (this->xml_namespace_.declarePrefix (ns_name, + attvalue) == -1) + { + this->fatal_error(ACE_TEXT ("Duplicate definition of ") + ACE_TEXT ("prefix") + ACEXML_ENV_ARG_PARAMETER); + return; + } } - if (this->skip_whitespace (0) != '>') + if (this->namespace_prefixes_) { - this->report_fatal_error(ACE_TEXT ("Expecting '>' in an end-tag") ACEXML_ENV_ARG_PARAMETER); - return; + // Namespace_prefixes_feature_ is required. So add the + // xmlns:foo to the list of attributes. + if (attributes.addAttribute (0, 0, attname, + default_attribute_type, + attvalue) == -1) + { + this->fatal_error(ACE_TEXT ("Duplicate attribute ") + ACE_TEXT ("definition. Hint: Try ") + ACE_TEXT ("setting namespace_prefix") + ACE_TEXT ("es feature to 0") + ACEXML_ENV_ARG_PARAMETER); + return; + } } - this->content_handler_->endElement (ns_uri, ns_lname, endname ACEXML_ENV_ARG_PARAMETER); - ACEXML_CHECK; - prefix = ACE_const_cast (ACEXML_Char*, - this->xml_namespace_.getPrefix(ns_uri)); - this->report_prefix_mapping (prefix, ns_uri, ns_lname, 0 ACEXML_ENV_ARG_PARAMETER); - ACEXML_CHECK; - if (new_namespace != 0) - this->xml_namespace_.popContext (); - return; - } - default: // a new nested element? - this->parse_element (0 ACEXML_ENV_ARG_PARAMETER); - ACEXML_CHECK; - break; - } - break; - case '&': - { - const ACEXML_String *replace = 0; - ACEXML_String charval; - ACEXML_Char buffer[6]; - - if (this->peek () == '#') - { - if (this->parse_char_reference (buffer, 6) != 0) + if (!this->namespaces_ && !this->namespace_prefixes_) { - // not referring to any character exception? + this->fatal_error(ACE_TEXT ("One of namespaces or ") + ACE_TEXT ("namespace_prefixes should be") + ACE_TEXT (" declared") + ACEXML_ENV_ARG_PARAMETER); return; } - charval.set (buffer, 0); - replace = &charval; } else - replace = this->parse_reference (); - - if (replace == 0) { - this->report_fatal_error(ACE_TEXT ("Internal error") ACEXML_ENV_ARG_PARAMETER); - return; + const ACEXML_Char *uri, *lName; + this->xml_namespace_.processName (attname, uri, lName, 1); + if (attributes.addAttribute (uri, lName, attname, + default_attribute_type, + attvalue) == -1) + { + this->fatal_error(ACE_TEXT ("Duplicate attribute ") + ACE_TEXT ("definition") + ACEXML_ENV_ARG_PARAMETER); + return; + } } -// if (this->try_grow_cdata (replace->length (), -// cdata_length, xmlenv) == 0) -// { - cdata_length += replace->length (); - for (size_t i = 0; i < replace->length (); ++i) - this->obstack_.grow ((*replace)[i]); -// } -// else -// return; - } - break; - case 0x0D: // End-of-Line handling - ch = (this->peek () == 0x0A ? this->get () : 0x0A); - // Fall thru... - case 0x0A: - // Fall thru... - default: - ++cdata_length; - cdata = this->obstack_.grow (ch); - if (cdata == 0) - { - cdata = this->obstack_.freeze (); - this->content_handler_->characters (cdata, 0, - ACE_static_cast (int, cdata_length) - ACEXML_ENV_ARG_PARAMETER); - ACEXML_CHECK; - this->obstack_.grow (ch); - cdata_length = 1; // the missing char. - } + break; } } - ACE_NOTREACHED (return;) + if (this->parse_content (startname, ns_uri, ns_lname + ACEXML_ENV_ARG_PARAMETER) != 0) + return; } int -ACEXML_Parser::parse_char_reference (ACEXML_Char *buf, size_t len) +ACEXML_Parser::parse_content (const ACEXML_Char* startname, + const ACEXML_Char* ns_uri, + const ACEXML_Char* ns_lname ACEXML_ENV_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) { - if (this->get () != '#') - { - // Internal error. - return -1; - } - - int hex = 0; - - if (this->peek () == 'x') - { - hex = 1; - this->get (); - } - - int more_digit = 0; - ACEXML_UCS4 sum = 0; + ACEXML_Char *cdata; + size_t cdata_length = 0; + // Parse element contents. while (1) { ACEXML_Char ch = this->get (); switch (ch) { - case '0': - case '1': - case '2': - case '3': - case '4': - case '5': - case '6': - case '7': - case '8': - case '9': - sum = sum * (hex ? 16 : 10) + (ch - '0'); - break; - case 'a': - case 'A': - if (!hex) - return -1; - sum = sum * 16 + 10; - break; - case 'b': - case 'B': - if (!hex) - return -1; - sum = sum * 16 + 11; - break; - case 'c': - case 'C': - if (!hex) - return -1; - sum = sum * 16 + 12; - break; - case 'd': - case 'D': - if (!hex) - return -1; - sum = sum * 16 + 13; - break; - case 'e': - case 'E': - if (!hex) - return -1; - sum = sum * 16 + 14; - break; - case 'f': - case 'F': - if (!hex) - return -1; - sum = sum * 16 + 15; - break; - case ';': - if (more_digit == 0) // no digit exist??? - return -1; - int clen; -#if defined (ACE_USES_WCHAR) // UTF-16 - if ((clen = ACEXML_Transcoder::ucs42utf16 (sum, buf, len)) < 0) - return -1; - -#elif 1 // or UTF-8 - if ((clen = ACEXML_Transcoder::ucs42utf8 (sum, buf, len)) < 0) - return -1; - // #elif 0 // UCS 4, not likely - // buf [0] = sum; - // buf [1] = 0; -#endif - buf [clen] = 0; - return 0; - default: - return -1; + case 0: + this->pop_context (1 ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + break; + case '<': + // Push out old 'characters' event. + if (cdata_length != 0) + { + cdata = this->obstack_.freeze (); + this->content_handler_->characters (cdata, 0, cdata_length + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + this->obstack_.unwind (cdata); + cdata_length = 0; + } + ch = this->peek(); + switch (ch) + { + case '!': // a comment or a CDATA section. + this->get (); // consume '!' + ch = this->peek (); + if (ch == '-') // a comment + { + if (this->parse_comment () < 0) + { + this->fatal_error(ACE_TEXT ("Invalid comment in ") + ACE_TEXT ("document") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + } + else if (ch == '[') // a CDATA section. + { + this->parse_cdata (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + else + { + this->fatal_error(ACE_TEXT ("Expecting a CDATA section ") + ACE_TEXT ("or a comment section") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + break; + case '?': // a PI. + this->get(); // consume the '?' + this->parse_processing_instruction + (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + break; + case '/': // an ETag. + { + this->get (); // consume '/' + ACEXML_Char* endname = this->parse_name (); + if (endname == 0 || + ACE_OS::strcmp (startname, endname) != 0) + { + this->fatal_error(ACE_TEXT ("Name in ETag doesn't ") + ACE_TEXT ("match name in STag") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + if (this->skip_whitespace () != '>') + { + this->fatal_error(ACE_TEXT ("Expecting '>' at end ") + ACE_TEXT ("of element") + ACEXML_ENV_ARG_PARAMETER); + return -1; + } + this->content_handler_->endElement (ns_uri, ns_lname, + endname + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + this->prefix_mapping (this->xml_namespace_.getPrefix(ns_uri), + ns_uri, ns_lname, 0 + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + if (this->nested_namespace_ >= 1) + { + this->xml_namespace_.popContext (); + this->nested_namespace_--; + } + return 0; + } + default: // a new nested element? + this->parse_element (0 ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + break; + } + break; + case '&': + if (this->peek () == '#') + { + ACEXML_Char buf[7]; + size_t len = 0; + do + { + len = sizeof (buf); + if (this->parse_char_reference (buf, len) != 0) + { + // [WFC: Legal Character] + this->fatal_error (ACE_TEXT ("Invalid CharRef") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + } while (buf[0] == '&' && this->peek() == '#'); + for (size_t j = 0; j < len; ++j) + this->obstack_.grow (buf[j]); + cdata_length += len; + } + else + { + this->ref_state_ = ACEXML_ParserInt::IN_CONTENT; + int length = this->parse_entity_reference(ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + if (length == 1) + cdata_length++; + } + break; + case '\x20': case '\x0D': case '\x0A': case '\x09': +// if (this->validate_) +// { +// // Flush out any non-whitespace characters +// if (cdata_length != 0) +// { +// cdata = this->obstack_.freeze (); +// this->content_handler_->characters(cdata, 0, cdata_length +// ACEXML_ENV_ARG_PARAMETER); +// ACEXML_CHECK_RETURN (-1); +// this->obstack_.unwind (cdata); +// cdata_length = 0; +// } +// ++cdata_length; +// this->obstack_.grow (ch); +// while (1) +// { +// ch = this->peek(); +// if (ch == '\x20' || ch == '\x0D' || ch == '\x0A' || +// ch == '\x09') +// { +// ch = this->get(); +// this->obstack_.grow (ch); +// continue; +// } +// break; +// } +// cdata = this->obstack_.freeze (); +// this->content_handler_->ignorableWhitespace (cdata, 0, +// cdata_length +// ACEXML_ENV_ARG_PARAMETER); +// ACEXML_CHECK_RETURN (-1); +// this->obstack_.unwind (cdata); +// cdata_length = 0; +// break; +// } + // Fall thru... + default: + ++cdata_length; + this->obstack_.grow (ch); } - more_digit = 1; } - ACE_NOTREACHED (return -1); + return 0; } -const ACEXML_String * -ACEXML_Parser::parse_reference (void) -{ - // @@ We'll use a temporary buffer here as the Obstack is most likely in - // use when we are here. This puts a limit on the max length of a - // reference. - ACEXML_Char ref[MAXPATHLEN]; - - size_t loc = 0; - - while (loc < MAXPATHLEN -1) - { - ACEXML_Char ch = this->get (); - if (ch == ';') - { - ref[loc] = 0; - break; - } - else - ref[loc++] = ch; - } - - return this->entities_.resolve_entity (ref); -} int ACEXML_Parser::parse_cdata (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) { if (this->parse_token (ACE_TEXT ("[CDATA[")) < 0) { - this->report_fatal_error(ACE_TEXT ("'[CDATA[' expected") ACEXML_ENV_ARG_PARAMETER); - return -1; + this->fatal_error(ACE_TEXT ("Expecting '[CDATA[' at beginning of CDATA ") + ACE_TEXT ("section") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } - int parse_state = 0; - size_t datalen = 0; - + ACEXML_Char ch; + int datalen = 0; + ACEXML_Char *cdata = 0; while (1) { - ACEXML_Char ch; - ACEXML_Char *cdata; - ch = this->get (); // Anything goes except the sequence "]]>". - switch (parse_state) + if (ch == ']' && this->peek() == ']') { - case 2: - if (ch == ']') - { - parse_state = 3; - continue; - } - break; - case 3: - if (ch == '>') // Yay! + ACEXML_Char temp = ch; + ch = this->get(); + if (ch == ']' && this->peek() == '>') { + ch = this->get(); cdata = this->obstack_.freeze (); - this->content_handler_->characters (cdata, 0, - ACE_static_cast (int, datalen) + this->content_handler_->characters (cdata, 0, datalen ACEXML_ENV_ARG_PARAMETER); - // ACEXML_CHECK_RETURN (-1); + ACEXML_CHECK_RETURN (-1); this->obstack_.unwind(cdata); return 0; } - break; - default: - if (ch == ']') - { - parse_state = 2; - continue; - } - else - parse_state = 1; - } - while (parse_state > 0) - { - if (this->try_grow_cdata (1, datalen ACEXML_ENV_ARG_PARAMETER) < 0) - return -1; - - if (parse_state != 1) - this->obstack_.grow (']'); - else - { - if (ch == 0x0D) - ch = (this->peek () == 0x0A ? this->get () : 0x0A); - this->obstack_.grow (ch); - } + this->obstack_.grow (temp); ++datalen; - --parse_state; } + this->obstack_.grow (ch); + ++datalen; }; ACE_NOTREACHED (return -1); } -int -ACEXML_Parser::try_grow_cdata (size_t size, size_t &len ACEXML_ENV_ARG_DECL) -{ - if (this->obstack_.request (size) != 0) - { - if (len != 0) - { - ACEXML_Char *cdata = this->obstack_.freeze (); - if (cdata == 0) - { - this->report_fatal_error(ACE_TEXT ("Internal Error growing CDATA buffer") ACEXML_ENV_ARG_PARAMETER); - return -1; - } - this->content_handler_->characters (cdata, - 0, - ACE_static_cast (int, len) - ACEXML_ENV_ARG_PARAMETER); - ACEXML_CHECK_RETURN (-1); - len = 0; // reset counter - if (this->obstack_.request (size) == 0) - return 0; - } - this->report_fatal_error(ACE_TEXT ("Internal Error, buffer overflowed") ACEXML_ENV_ARG_PARAMETER); - return -1; - } - return 0; -} - - -int -ACEXML_Parser::parse_internal_dtd (ACEXML_ENV_SINGLE_ARG_DECL) -{ - ACEXML_Char nextch = this->skip_whitespace (0); - - do { - switch (nextch) - { - case '<': // Start of markup Decl. - nextch = this->peek (); - switch (nextch) - { - case '!': - this->get (); // Discard '!' - nextch = this->peek (); - switch (nextch) - { - case 'E': // An ELEMENT or ENTITY decl - this->get (); - nextch = this->peek (); - switch (nextch) - { - case 'L': - if (this->parse_element_decl (ACEXML_ENV_SINGLE_ARG_PARAMETER) < 0) - return -1; - break; - - case 'N': - if (this->parse_entity_decl (ACEXML_ENV_SINGLE_ARG_PARAMETER) < 0) - return -1; - break; - - default: - this->report_fatal_error(ACE_TEXT ("Invalid keyword in decl spec") ACEXML_ENV_ARG_PARAMETER); - return -1; - } - break; - - case 'A': // An ATTLIST decl - if (this->parse_attlist_decl (ACEXML_ENV_SINGLE_ARG_PARAMETER) < 0) - return -1; - break; - - case 'N': // A NOTATION decl - if (this->parse_notation_decl (ACEXML_ENV_SINGLE_ARG_PARAMETER) < 0) - return -1; - break; - - case '-': // a comment. - if (this->grok_comment () < 0) - { - this->report_fatal_error(ACE_TEXT ("Error parsing comment") ACEXML_ENV_ARG_PARAMETER); - return -1; - } - break; - case 0: - this->report_fatal_error (ACE_TEXT ("Unexpected EOF") ACEXML_ENV_ARG_PARAMETER); - return -1; - default: - this->report_fatal_error (ACE_TEXT ("Invalid char. follows '<!' in markupdecl") ACEXML_ENV_ARG_PARAMETER); - return -1; - } - break; - - case '?': // PI - this->parse_processing_instruction (ACEXML_ENV_SINGLE_ARG_PARAMETER); - ACEXML_CHECK_RETURN (-1); - break; - - case 0: - this->report_fatal_error (ACE_TEXT ("Unexpected EOF") ACEXML_ENV_ARG_PARAMETER); - return -1; - default: - this->report_fatal_error (ACE_TEXT ("Invalid char. follows '<!' in markupdecl") ACEXML_ENV_ARG_PARAMETER); - return -1; - } - break; - - case '%': // DeclSep. Define new PEreference... - break; - - case ']': // End of internal definitions. - return 0; // Not applicable when parsing external DTD spec. - - 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_TEXT ("Unexpected EOF") ACEXML_ENV_ARG_PARAMETER); - return -1; - - default: - this->report_fatal_error (ACE_TEXT ("Expecting markupdecl or DecSep") ACEXML_ENV_ARG_PARAMETER); - return -1; - }; - - // To fully conform with the spec., whitespaces are only allowed - // following a 'DeclSep' section. However, I found it - // hard/impossible to eliminate all the whitespaces between - // markupdecls. - - nextch = this->skip_whitespace (0); - - } while (1); - - ACE_NOTREACHED (return -1); -} - -int -ACEXML_Parser::parse_element_decl (ACEXML_ENV_SINGLE_ARG_DECL) -{ - if ((this->parse_token (ACE_TEXT ("LEMENT")) < 0) || - this->skip_whitespace_count () == 0) - { - this->report_fatal_error (ACE_TEXT ("Expecting keyword `ELEMENT'") ACEXML_ENV_ARG_PARAMETER); - return -1; - } - - ACEXML_Char *element_name = this->read_name (); - if (element_name == 0) - { - this->report_fatal_error (ACE_TEXT ("Error reading element name while defining ELEMENT.") ACEXML_ENV_ARG_PARAMETER); - return -1; - } - - ACEXML_Char nextch ; - this->skip_whitespace_count (&nextch); - - switch (nextch) - { - case 'E': // EMPTY - if (this->parse_token (ACE_TEXT ("EMPTY")) < 0) - { - this->report_fatal_error (ACE_TEXT ("Expecting keyword `EMPTY' in ELEMENT definition.") ACEXML_ENV_ARG_PARAMETER); - return -1; - } - break; - case 'A': // ANY - if (this->parse_token (ACE_TEXT ("ANY")) < 0) - { - this->report_fatal_error (ACE_TEXT ("Expecting keyword `ANY' in ELEMENT definition.") ACEXML_ENV_ARG_PARAMETER); - return -1; - } - break; - case '(': // children - this->parse_children_definition (ACEXML_ENV_SINGLE_ARG_PARAMETER); - ACEXML_CHECK_RETURN (-1); - break; - default: // error - this->report_fatal_error (ACE_TEXT ("Error reading ELEMENT definition.") ACEXML_ENV_ARG_PARAMETER); - return -1; - } - if (this->skip_whitespace (0) != '>') - { - this->report_fatal_error (ACE_TEXT ("Expecting '>' in ELEMENT definition.") ACEXML_ENV_ARG_PARAMETER); - return -1; - } - return 0; -} int ACEXML_Parser::parse_entity_decl (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) { ACEXML_Char nextch; if ((this->parse_token (ACE_TEXT ("NTITY")) < 0) || this->skip_whitespace_count (&nextch) == 0) { - this->report_fatal_error (ACE_TEXT ("Expecting keyword `ENTITY'") ACEXML_ENV_ARG_PARAMETER); - return -1; + this->fatal_error (ACE_TEXT ("Expecting keyword ENTITY followed by a ") + ACE_TEXT ("space") ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } int is_GEDecl = 1; @@ -1168,326 +1188,298 @@ ACEXML_Parser::parse_entity_decl (ACEXML_ENV_SINGLE_ARG_DECL) this->get (); // consume the '%' if (this->skip_whitespace_count (&nextch) == 0) { - this->report_fatal_error (ACE_TEXT ("Can't use a reference when defining entity name") ACEXML_ENV_ARG_PARAMETER); - return -1; + this->fatal_error (ACE_TEXT ("Expecting space between % and ") + ACE_TEXT ("entity name") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } } - ACEXML_Char *entity_name = this->read_name (); + ACEXML_Char *entity_name = this->parse_name (); if (entity_name == 0) { - this->report_fatal_error (ACE_TEXT ("Error reading ENTITY name.") ACEXML_ENV_ARG_PARAMETER); - return -1; + this->fatal_error (ACE_TEXT ("Invalid entity name") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } - this->skip_whitespace_count (&nextch); - + if (this->skip_whitespace_count (&nextch) == 0) + { + this->fatal_error (ACE_TEXT ("Expecting space between entity name and ") + ACE_TEXT ("entityDef") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + int retval = 0; if (nextch == '\'' || nextch == '"') { ACEXML_Char *entity_value = 0; - - if (this->get_quoted_string (entity_value) != 0) + if (this->parse_entity_value (entity_value + ACEXML_ENV_ARG_PARAMETER) != 0) { - this->report_fatal_error(ACE_TEXT("Error reading ENTITY value.") ACEXML_ENV_ARG_PARAMETER); - return -1; + this->fatal_error(ACE_TEXT ("Invalid EntityValue") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } - if (is_GEDecl) + retval = this->internal_GE_.add_entity (entity_name, + entity_value); + else + retval = this->internal_PE_.add_entity (entity_name, + entity_value); + if (retval < 0) { - if (this->entities_.add_entity (entity_name, entity_value) != 0) - { - this->report_fatal_error(ACE_TEXT("Error storing entity definition (duplicate definition?)") ACEXML_ENV_ARG_PARAMETER); - return -1; - } + this->fatal_error (ACE_TEXT ("Internal Parser Error in adding") + ACE_TEXT ("Entity to map") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } - else + else if (retval == 1) { - // @@ need to implement PEdecl lookup mechanism - ACEXML_THROW_RETURN (ACEXML_SAXNotSupportedException (), -1); + this->warning (ACE_TEXT ("Duplicate entity found") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } } else { ACEXML_Char *systemid, *publicid; - this->parse_external_id_and_ref (publicid, systemid ACEXML_ENV_ARG_PARAMETER); + this->parse_external_id (publicid, systemid + ACEXML_ENV_ARG_PARAMETER); ACEXML_CHECK_RETURN (-1); if (systemid == 0) { - this->report_fatal_error(ACE_TEXT("Invalid ExternalID definition (system ID missing.)") ACEXML_ENV_ARG_PARAMETER); - return -1; + this->fatal_error(ACE_TEXT ("Invalid SystemLiteral") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } this->skip_whitespace_count (&nextch); if (nextch == 'N') // NDATA section followed { if (is_GEDecl == 0) { - this->report_fatal_error(ACE_TEXT("Unexpected keyword NDATA in PEDecl.") ACEXML_ENV_ARG_PARAMETER); - return -1; + this->fatal_error(ACE_TEXT ("Invalid NDataDecl in PEDef") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } if ((this->parse_token (ACE_TEXT ("NDATA")) < 0) || this->skip_whitespace_count (&nextch) == 0) { - this->report_fatal_error(ACE_TEXT("Expecting keyword NDATA") ACEXML_ENV_ARG_PARAMETER); - return -1; + this->fatal_error(ACE_TEXT ("Expecting keyword NDATA followed ") + ACE_TEXT ("by a space") ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } - ACEXML_Char *ndata = this->read_name (); - this->dtd_handler_->unparsedEntityDecl (entity_name, - publicid, - systemid, - ndata ACEXML_ENV_ARG_PARAMETER); - ACEXML_CHECK_RETURN (-1); + ACEXML_Char *ndata = this->parse_name (); + if (this->validate_) // [VC: Notation Declared] + { + if (!this->notations_.resolve_entity (ndata)) + { + this->fatal_error (ACE_TEXT ("Undeclared Notation name") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + this->dtd_handler_->unparsedEntityDecl(entity_name, publicid, + systemid, ndata + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } } else { - // @@ Need to support external CharStream sources - ACE_DEBUG ((LM_DEBUG, - ACE_TEXT ("ENTITY: (%s) "), - entity_name)); - - if (publicid == 0) - ACE_DEBUG ((LM_DEBUG, - ACE_TEXT ("SYSTEM %s\n"), - systemid)); + if (is_GEDecl) + retval = this->external_GE_.add_entity (entity_name, + systemid); else - ACE_DEBUG ((LM_DEBUG, - ACE_TEXT ("PUBLIC %s %s\n"), - publicid, systemid)); + retval = this->external_PE_.add_entity (entity_name, + systemid); + if (retval < 0) + { + this->fatal_error(ACE_TEXT ("Internal Parser Error") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + else if (retval == 1) + this->warning(ACE_TEXT ("Duplicate external entity") + ACEXML_ENV_ARG_PARAMETER); + if (is_GEDecl) + retval = this->external_GE_.add_entity (entity_name, + publicid); + else + retval = this->external_PE_.add_entity (entity_name, + publicid); + if (retval < 0) + { + this->fatal_error(ACE_TEXT ("Internal Parser Error") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + else if (retval == 1) + this->warning (ACE_TEXT ("Duplicate entity definition") + ACEXML_ENV_ARG_PARAMETER); } } // End of ENTITY definition - if (this->skip_whitespace (0) != '>') + if (this->skip_whitespace() != '>') { - this->report_fatal_error(ACE_TEXT("Expecting end of ENTITY definition.") ACEXML_ENV_ARG_PARAMETER); - return -1; + this->fatal_error(ACE_TEXT ("Expecting '>' at end of entityDef") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } return 0; } int ACEXML_Parser::parse_attlist_decl (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) { - if ((this->parse_token (ACE_TEXT ("ATTLIST")) < 0) || - this->skip_whitespace_count () == 0) + if (this->parse_token (ACE_TEXT ("ATTLIST")) < 0) { - this->report_fatal_error(ACE_TEXT("Expecting keyword `ATTLIST'") ACEXML_ENV_ARG_PARAMETER); - return -1; + this->fatal_error(ACE_TEXT ("Expecting keyword 'ATTLIST'") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + int count = check_for_PE_reference (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + if (!count) + { + this->fatal_error(ACE_TEXT ("Expecting space between ATTLIST and ") + ACE_TEXT ("element name") ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } - ACEXML_Char *element_name = this->read_name (); + ACEXML_Char *element_name = this->parse_name (); if (element_name == 0) { - this->report_fatal_error(ACE_TEXT("Error reading element name while defining ATTLIST.") ACEXML_ENV_ARG_PARAMETER); - return -1; + this->fatal_error(ACE_TEXT ("Invalid element Name in attlistDecl") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } - - ACEXML_Char nextch = this->skip_whitespace (0); - + ACEXML_Char fwd = 0; + ACEXML_Char* attname = 0; + count = this->skip_whitespace_count (&fwd); // Parse AttDef* - while (nextch != '>') + while (fwd != '>') { - // Parse attribute name - ACEXML_Char *att_name = this->read_name (nextch); - if (att_name == 0) + if (!this->check_for_PE_reference (ACEXML_ENV_SINGLE_ARG_PARAMETER) + && !count) + this->fatal_error(ACE_TEXT ("Expecting space between element ") + ACE_TEXT ("name and AttDef") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + this->skip_whitespace_count (&fwd); + if (fwd == '>') + break; + attname = this->parse_attname (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + + count = this->check_for_PE_reference (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + if (!count) { - this->report_fatal_error(ACE_TEXT("Error reading attribute name while defining ATTLIST.") ACEXML_ENV_ARG_PARAMETER); - return -1; + this->fatal_error(ACE_TEXT ("Expecting space between AttName and ") + ACE_TEXT ("AttType") ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } + this->parse_atttype (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); - /* - Parse AttType: - Possible keywords: - CDATA // StringType - ID // TokenizedType - IDREF - IDREFS - ENTITY - ENTITIES - NMTOKEN - NMTOKENS - NOTATION // EnumeratedType - NotationTYpe - ( // EnumeratedType - Enumeration - */ - nextch = this->skip_whitespace (0); - switch (nextch) + count = this->check_for_PE_reference (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + if (!count) { - case 'C': // CDATA - if ((this->parse_token (ACE_TEXT ("DATA")) < 0) || - this->skip_whitespace_count () == 0) - { - this->report_fatal_error(ACE_TEXT("Expecting keyword `CDATA' while defining ATTLIST.") ACEXML_ENV_ARG_PARAMETER); - return -1; - } - // Else, we have successfully identified the type of the - // attribute as CDATA - // @@ Set up validator appropriately here. - break; - case 'I': // ID, IDREF, or, IDREFS - if (this->get () == 'D') - { - if (this->skip_whitespace_count (&nextch) > 0) - { - // We have successfully identified the type of the - // attribute as ID @@ Set up validator as such. - break; - } - if (this->parse_token (ACE_TEXT ("REF")) == 0) - { - if (this->skip_whitespace_count (&nextch) > 0) - { - // We have successfully identified the type of - // the attribute as IDREF - // @@ Set up validator as such. - break; - } - else if (nextch == 'S' && - this->get () && // consume the 'S' - this->skip_whitespace_count () != 0) - { - // We have successfully identified the type of - // the attribute as IDREFS - // @@ Set up validator as such. - break; - } - } - } - // Admittedly, this error message is not precise enough - this->report_fatal_error(ACE_TEXT("Expecting keyword `ID', `IDREF', or `IDREFS' while defining ATTLIST.") ACEXML_ENV_ARG_PARAMETER); - return -1; - case 'E': // ENTITY or ENTITIES - if (this->parse_token (ACE_TEXT ("NTIT")) == 0) - { - nextch = this->get (); - if (nextch == 'Y') - { - // We have successfully identified the type of - // the attribute as ENTITY - // @@ Set up validator as such. - } - else if (nextch == 'I'&& this->get () == 'E' && - this->get () == 'S') - { - // We have successfully identified the type of - // the attribute as ENTITIES - // @@ Set up validator as such. - } - if (this->skip_whitespace_count () > 0) - { - // success - break; - } - } - // Admittedly, this error message is not precise enough - this->report_fatal_error(ACE_TEXT("Expecting keyword `ENTITY', or `ENTITIES' while defining ATTLIST.") ACEXML_ENV_ARG_PARAMETER); - return -1; - case 'N': // NMTOKEN, NMTOKENS, or, NOTATION - nextch = this->get (); - if (nextch != 'M' || nextch != 'O') - { - this->report_fatal_error(ACE_TEXT("Expecting keyword `NMTOKEN', `NMTOKENS', or `NOTATION' while defining ATTLIST.") ACEXML_ENV_ARG_PARAMETER); - return -1; - } - if (nextch == 'M') - { - if (this->parse_token (ACE_TEXT ("TOKEN")) == 0) - { - if (this->skip_whitespace_count (&nextch) > 0) - { - // We have successfully identified the type of - // the attribute as NMTOKEN - // @@ Set up validator as such. - break; - } - else if (nextch == 'S' && this->skip_whitespace_count () > 0) - { - // We have successfully identified the type of - // the attribute as NMTOKENS - // @@ Set up validator as such. - break; - } - } - this->report_fatal_error(ACE_TEXT("Expecting keyword `NMTOKEN' or `NMTOKENS' while defining ATTLIST.") ACEXML_ENV_ARG_PARAMETER); - return -1; - } - else // NOTATION - { - if ((this->parse_token (ACE_TEXT ("TATION")) < 0) || - this->skip_whitespace_count () == 0) - { - this->report_fatal_error(ACE_TEXT("Expecting keyword `NOTATION' while defining ATTLIST.") ACEXML_ENV_ARG_PARAMETER); - return -1; - } - - if (this->get () != '(') - { - this->report_fatal_error(ACE_TEXT("Expecting `(' following NOTATION while defining ATTLIST.") ACEXML_ENV_ARG_PARAMETER); - return -1; - } + this->fatal_error(ACE_TEXT ("Expecting space between AttType and") + ACE_TEXT (" DefaultDecl") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + this->parse_defaultdecl (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); - this->skip_whitespace_count (); + count = this->check_for_PE_reference (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + this->skip_whitespace_count(&fwd); + } + this->get (); // consume closing '>' + return 0; +} - do { - ACEXML_Char *notation_name = this->read_name (); - if (notation_name == 0) - { - this->report_fatal_error(ACE_TEXT("Error reading NOTATION name while defining ATTLIST.") ACEXML_ENV_ARG_PARAMETER); - return -1; - } - // @@ get another notation name, set up validator as such - this->skip_whitespace_count (&nextch); - } while (nextch != ')'); - this->get (); // consume the closing paren. - this->skip_whitespace_count (); - } - break; - case '(': // EnumeratedType - Enumeration - this->skip_whitespace_count (); +int +ACEXML_Parser::check_for_PE_reference (ACEXML_ENV_SINGLE_ARG_DECL) +{ + ACEXML_Char fwd = '\xFF'; + // Skip any leading whitespaces and store the number of such chars skipped + int count = this->skip_whitespace_count (&fwd); + if (fwd == 0) + { + this->get(); // Consume the 0 + this->pop_context (0 ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + fwd = this->peek(); + } + if (fwd == '%') + { + this->get(); // Consume the % + if (this->external_subset_) + { + this->parse_PE_reference (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + else + { + this->fatal_error(ACE_TEXT ("Illegal PERef within markupDecl") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + } + if (count) + { + // We have atleast one whitespace. So just skip any more whitespaces + // and return the count + this->skip_whitespace_count(); + return count; + } + return this->skip_whitespace_count(); +} - do { - ACEXML_Char *token_name = this->read_name (); // @@ need a special read_nmtoken? - if (token_name == 0) - { - this->report_fatal_error(ACE_TEXT("Error reading enumerated nmtoken name while defining ATTLIST.") ACEXML_ENV_ARG_PARAMETER); - return -1; - } - // @@ get another nmtoken, set up validator as such - this->skip_whitespace_count (&nextch); - } while (nextch != ')'); +ACEXML_Char* +ACEXML_Parser::parse_attname (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) +{ + // Parse attribute name + ACEXML_Char *att_name = this->parse_name (); + if (att_name == 0) + { + this->fatal_error(ACE_TEXT ("Invalid AttName") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (0); + } + return att_name; +} - this->get (); // consume the closing paren. - this->skip_whitespace_count (); - break; - default: +int +ACEXML_Parser::parse_defaultdecl (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) +{ + // DefaultDecl ::= '#REQUIRED' | '#IMPLIED' | (('#FIXED' S)? AttValue) + ACEXML_Char nextch = this->peek (); + ACEXML_Char *fixed_attr = 0; + switch (nextch) + { + case '#': + this->get (); // consume the '#' + switch (this->get ()) { - this->report_fatal_error(ACE_TEXT("Invalid Attribute Type while defining ATTLIST.") ACEXML_ENV_ARG_PARAMETER); - return -1; - } - ACE_NOTREACHED (break); - } - - /* - Parse DefaultDecl: - #REQUIRED - #IMPLIED - #FIXED - quoted string // #FIXED - */ - nextch = this->peek (); - switch (nextch) - { - case '#': - this->get (); // consume the '#' - switch (this->get ()) - { case 'R': if (this->parse_token (ACE_TEXT ("EQUIRED")) < 0) { - this->report_fatal_error(ACE_TEXT("Expecting keyword `#REQUIRED' while defining ATTLIST.") ACEXML_ENV_ARG_PARAMETER); - return -1; + this->fatal_error(ACE_TEXT ("Expecting keyword REQUIRED") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } // We now know this attribute is required // @@ Set up the validator as such. @@ -1495,196 +1487,510 @@ ACEXML_Parser::parse_attlist_decl (ACEXML_ENV_SINGLE_ARG_DECL) case 'I': if (this->parse_token (ACE_TEXT ("MPLIED")) < 0) { - this->report_fatal_error(ACE_TEXT("Expecting keyword `#IMPLIED' while defining ATTLIST.") ACEXML_ENV_ARG_PARAMETER); - return -1; + this->fatal_error(ACE_TEXT ("Expecting keyword IMPLIED") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } - // We now know this attribute is impleid. + // We now know this attribute is implied. // @@ Set up the validator as such. break; case 'F': if (this->parse_token (ACE_TEXT ("IXED")) < 0 || this->skip_whitespace_count () == 0) { - this->report_fatal_error(ACE_TEXT("Expecting keyword `#FIXED' while defining ATTLIST.") ACEXML_ENV_ARG_PARAMETER); - return -1; + this->fatal_error(ACE_TEXT ("Expecting keyword FIXED") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } // We now know this attribute is fixed. - - ACEXML_Char *fixed_attr; - if (this->get_quoted_string (fixed_attr) != 0) + if (this->parse_attvalue (fixed_attr + ACEXML_ENV_ARG_PARAMETER) != 0) { - this->report_fatal_error(ACE_TEXT("Error parsing `#FIXED' attribute value while defining ATTLIST.") ACEXML_ENV_ARG_PARAMETER); - return -1; + this->fatal_error(ACE_TEXT ("Invalid Default AttValue") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } // @@ set up validator break; default: - break; - } - break; - case '\'': - case '"': - ACEXML_Char *fixed_attr; - if (this->get_quoted_string (fixed_attr) != 0) + this->fatal_error (ACE_TEXT ("Invalid DefaultDecl") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + break; + case '\'': + case '"': + if (this->parse_attvalue (fixed_attr ACEXML_ENV_ARG_PARAMETER) != 0) + { + this->fatal_error(ACE_TEXT ("Invalid AttValue") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + // @@ set up validator + break; + default: + this->fatal_error (ACE_TEXT ("Invalid DefaultDecl") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + break; + } + return 0; +} + +int +ACEXML_Parser::parse_tokenized_type (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) +{ + ACEXML_Char ch = this->get(); + switch (ch) + { + case 'I': + if (this->get () == 'D') + { + if (this->peek() != 'R' && this->is_whitespace (this->peek())) + { + // We have successfully identified the type of the + // attribute as ID + // @@ Set up validator as such. + break; + } + if (this->parse_token (ACE_TEXT ("REF")) == 0) + { + if (this->peek() != 'S' && this->is_whitespace (this->peek())) + { + // We have successfully identified the type of + // the attribute as IDREF + // @@ Set up validator as such. + break; + } + else if (this->peek() == 'S' + && this->get() // consume the 'S' + && this->is_whitespace (this->peek())) + { + // We have successfully identified the type of + // the attribute as IDREFS + // @@ Set up validator as such. + break; + } + } + } + // Admittedly, this error message is not precise enough + this->fatal_error(ACE_TEXT ("Expecting keyword `ID', `IDREF', or") + ACE_TEXT ("`IDREFS'") ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + case 'E': // ENTITY or ENTITIES + if (this->parse_token (ACE_TEXT ("NTIT")) == 0) + { + ACEXML_Char nextch = this->get (); + if (nextch == 'Y') + { + // We have successfully identified the type of + // the attribute as ENTITY + // @@ Set up validator as such. + } + else if (this->parse_token (ACE_TEXT ("IES")) == 0) + { + // We have successfully identified the type of + // the attribute as ENTITIES + // @@ Set up validator as such. + } + if (this->is_whitespace (this->peek())) + { + // success + break; + } + } + // Admittedly, this error message is not precise enough + this->fatal_error(ACE_TEXT ("Expecting keyword `ENTITY', or") + ACE_TEXT ("`ENTITIES'") ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + case 'M': + if (this->parse_token (ACE_TEXT ("TOKEN")) == 0) + { + if (this->is_whitespace (this->peek())) + { + // We have successfully identified the type of + // the attribute as NMTOKEN + // @@ Set up validator as such. + break; + } + else if (this->peek() == 'S' + && this->get() + && this->is_whitespace (this->peek())) + { + // We have successfully identified the type of + // the attribute as NMTOKENS + // @@ Set up validator as such. + break; + } + } + this->fatal_error(ACE_TEXT ("Expecting keyword `NMTOKEN' or `NMTO") + ACE_TEXT ("KENS'") ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + break; + default: + this->fatal_error (ACE_TEXT ("Internal Parser Error") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + break; + } + return 0; +} + + +/** + * AttType ::= StringType | TokenizedType | EnumeratedType + * StringType ::= 'CDATA' + * TokenizedType ::= 'ID' [VC: ID] + * [VC: One ID per Element Type] + * [VC: ID Attribute Default] + * | 'IDREF' [VC: IDREF] + * | 'IDREFS' [VC: IDREF] + * | 'ENTITY' [VC: Entity Name] + * | 'ENTITIES' [VC: Entity Name] + * | 'NMTOKEN' [VC: Name Token] + * | 'NMTOKENS' + * + * EnumeratedType ::= NotationType | Enumeration + * NotationType ::= 'NOTATION' S '(' S? Name (S? '|' S? Name)* S? ')' + * [VC: Notation Attributes] + * [VC: One Notation Per Element Type] + * [VC: No Notation on Empty Element] + * Enumeration ::= '(' S? Nmtoken (S? '|' S? Nmtoken)* S? ')' + * [VC: Enumeration] + */ +int +ACEXML_Parser::parse_atttype (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) +{ + ACEXML_Char nextch = this->peek(); + switch (nextch) + { + case 'C': // CDATA + if (this->parse_token (ACE_TEXT ("CDATA")) < 0) + { + this->fatal_error(ACE_TEXT ("Expecting keyword 'CDATA'") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + // Else, we have successfully identified the type of the + // attribute as CDATA + // @@ Set up validator appropriately here. + break; + case 'I': case 'E': // ID, IDREF, IDREFS, ENTITY or ENTITIES + this->parse_tokenized_type (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + break; + case 'N': // NMTOKEN, NMTOKENS, or NOTATION + this->get(); + nextch = this->peek(); + if (nextch != 'M' && nextch != 'O') + { + this->fatal_error (ACE_TEXT ("Expecting keyword 'NMTOKEN', ") + ACE_TEXT ("'NMTOKENS' or 'NOTATION'") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + if (nextch == 'M') + { + this->parse_tokenized_type (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + break; + } + else // NOTATION + { + if (this->parse_token (ACE_TEXT ("OTATION")) < 0) + { + this->fatal_error(ACE_TEXT ("Expecting keyword `NOTATION'") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + int count = this->check_for_PE_reference (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + if (!count) + { + this->fatal_error (ACE_TEXT ("Expecting space between keyword ") + ACE_TEXT ("NOTATION and '('") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + if (this->get () != '(') + { + this->fatal_error(ACE_TEXT ("Expecting '(' in NotationType") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + this->check_for_PE_reference (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + do { + this->skip_whitespace_count(); + ACEXML_Char *notation_name = this->parse_name (); + if (notation_name == 0) + { + this->fatal_error(ACE_TEXT ("Invalid notation name") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + // @@ get another notation name, set up validator as such + this->check_for_PE_reference (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + nextch = this->get(); + } while (nextch == '|'); + if (nextch != ')') + { + this->fatal_error (ACE_TEXT ("Expecting a ')' after a ") + ACE_TEXT ("NotationType declaration") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + } + break; + case '(': // EnumeratedType - Enumeration + this->get(); + this->check_for_PE_reference (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + do { + this->skip_whitespace_count(); + ACEXML_Char *token_name = this->parse_nmtoken (); + if (token_name == 0) { - this->report_fatal_error(ACE_TEXT("Error parsing `#FIXED' attribute value while defining ATTLIST.") ACEXML_ENV_ARG_PARAMETER); - return -1; + this->fatal_error(ACE_TEXT ("Invalid enumeration name") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } - // @@ set up validator - break; - default: - break; + // @@ get another nmtoken, set up validator as such + this->check_for_PE_reference (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + nextch = this->get(); + } while (nextch == '|'); + if (nextch != ')') + { + this->fatal_error (ACE_TEXT ("Expecting a ')' after a ") + ACE_TEXT ("Enumeration declaration") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + break; + default: + { + this->fatal_error(ACE_TEXT ("Invalid AttType") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } - this->skip_whitespace_count (&nextch); + ACE_NOTREACHED (break); } - - this->get (); // consume closing '>' - return 0; } int ACEXML_Parser::parse_notation_decl (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) { - if (this->parse_token (ACE_TEXT ("NOTATION")) < 0 || - this->skip_whitespace_count () == 0) + if (this->parse_token (ACE_TEXT ("NOTATION")) < 0) { - this->report_fatal_error(ACE_TEXT("Expecting keyword `NOTATION'") ACEXML_ENV_ARG_PARAMETER); - return -1; + this->fatal_error(ACE_TEXT ("Expecting Keyword 'NOTATION'") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } - - ACEXML_Char *notation = this->read_name (); + int count = this->check_for_PE_reference (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + if (!count) + { + this->fatal_error (ACE_TEXT ("Expecting a space between keyword NOTATION") + ACE_TEXT (" and notation name") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + ACEXML_Char *notation = this->parse_name (); if (notation == 0) { - this->report_fatal_error(ACE_TEXT("Invalid notation name.") ACEXML_ENV_ARG_PARAMETER); - return -1; + this->fatal_error(ACE_TEXT ("Invalid Notation name") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + count = this->check_for_PE_reference (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + if (!count) + { + this->fatal_error (ACE_TEXT ("Expecting a space between notation name ") + ACE_TEXT ("and ExternalID/PublicID") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } - this->skip_whitespace_count (); ACEXML_Char *systemid, *publicid; - this->parse_external_id_and_ref (publicid, systemid ACEXML_ENV_ARG_PARAMETER); + // Gross hack but otherwise we need to go around a lot of loops to parse, + // When the ExternalID starts with 'PUBLIC' we cannot distinguish a + // PublicId from a ExternalID by looking using a one character read-ahead + ACEXML_ParserInt::ReferenceState temp = this->ref_state_; + this->ref_state_ = ACEXML_ParserInt::IN_NOTATION; + + this->parse_external_id (publicid, systemid + ACEXML_ENV_ARG_PARAMETER); ACEXML_CHECK_RETURN (-1); + // Restore the original value. + this->ref_state_ = temp; - if (this->get () != '>') + // [VC: Unique Notation Name] + if (systemid && this->notations_.add_entity (notation, systemid) != 0 + && this->validate_) { - this->report_fatal_error(ACE_TEXT("Expecting NOTATION closing '>'.") ACEXML_ENV_ARG_PARAMETER); - return -1; + this->fatal_error(ACE_TEXT ("Internal Parser Error") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + if (publicid) + { + int retval = this->notations_.add_entity (notation, publicid); + if (retval != 0 && !systemid && this->validate_) + { + this->fatal_error(ACE_TEXT ("Internal Parser Error") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } } - this->dtd_handler_->notationDecl (notation, - publicid, - systemid ACEXML_ENV_ARG_PARAMETER); - ACEXML_CHECK_RETURN (-1); + if (this->skip_whitespace() != '>') + { + this->fatal_error(ACE_TEXT ("Expecting '>' at end of NotationDecl") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + if (this->validate_ && this->dtd_handler_) + { + this->dtd_handler_->notationDecl (notation, + publicid, + systemid ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } return 0; } int -ACEXML_Parser::parse_external_id_and_ref (ACEXML_Char *&publicId, - ACEXML_Char *&systemId ACEXML_ENV_ARG_DECL) +ACEXML_Parser::parse_element_decl (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) { - publicId = systemId = 0; - ACEXML_Char nextch = this->get (); - + if (this->parse_token (ACE_TEXT ("LEMENT")) < 0) + { + this->fatal_error (ACE_TEXT ("Expecting keyword ELEMENT") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + int count = this->check_for_PE_reference (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + if (!count) + { + this->fatal_error (ACE_TEXT ("Expecting a space between keyword ELEMENT") + ACE_TEXT (" and element name") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + ACEXML_Char *element_name = this->parse_name (); + if (element_name == 0) + { + this->fatal_error (ACE_TEXT ("Invalid element name") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + count = this->check_for_PE_reference (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + if (!count) + { + this->fatal_error (ACE_TEXT ("Expecting a space between element name ") + ACE_TEXT ("and element definition") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + ACEXML_Char nextch = this->peek(); switch (nextch) { - case 'S': // External SYSTEM id. - if (this->parse_token (ACE_TEXT ("YSTEM")) < 0 || - this->skip_whitespace_count () == 0) - { - this->report_fatal_error(ACE_TEXT("Expecting keyword 'SYSTEM'") ACEXML_ENV_ARG_PARAMETER); - return -1; - } - if (this->get_quoted_string (systemId) != 0) - { - this->report_fatal_error(ACE_TEXT("Error while parsing SYSTEM literal for SYSTEM id.") ACEXML_ENV_ARG_PARAMETER); - return -1; - } - this->locator_.setSystemId (systemId); - break; - case 'P': // External PUBLIC id or previously defined PUBLIC id. - if (this->parse_token (ACE_TEXT ("UBLIC")) < 0 || - this->skip_whitespace_count () == 0) - { - this->report_fatal_error(ACE_TEXT("Expecting keyword 'PUBLIC'") ACEXML_ENV_ARG_PARAMETER); - return -1; - } - if (this->get_quoted_string (publicId) != 0) - { - this->report_fatal_error(ACE_TEXT("Error while parsing public literal for PUBLIC id.") ACEXML_ENV_ARG_PARAMETER); - return -1; - } - this->locator_.setPublicId (publicId); - - this->skip_whitespace_count (&nextch); - if (nextch == '\'' || nextch == '"') // not end of NOTATION yet. - { - if (this->get_quoted_string (systemId) != 0) - { - this->report_fatal_error(ACE_TEXT("Error while parsing system literal for PUBLIC id.") ACEXML_ENV_ARG_PARAMETER); - return -1; - } - this->locator_.setSystemId (systemId); - } - break; - default: - this->report_fatal_error(ACE_TEXT("Expecting either keyword `SYSTEM' or `PUBLIC'.") ACEXML_ENV_ARG_PARAMETER); - return -1; + case 'E': // EMPTY + if (this->parse_token (ACE_TEXT ("EMPTY")) < 0) + { + this->fatal_error (ACE_TEXT ("Expecting keyword EMPTY") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + break; + case 'A': // ANY + if (this->parse_token (ACE_TEXT ("ANY")) < 0) + { + this->fatal_error (ACE_TEXT ("Expecting keyword ANY") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + break; + case '(': // children + this->parse_children_definition (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + break; + default: // error + this->fatal_error (ACE_TEXT ("Invalid element definition") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + count = this->check_for_PE_reference (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + if (this->skip_whitespace () != '>') + { + this->fatal_error (ACE_TEXT ("Expecting '>' after element defintion") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } return 0; } + int ACEXML_Parser::parse_children_definition (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) { this->get (); // consume the '(' - - ACEXML_Char nextch; + this->check_for_PE_reference (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); int subelement_number = 0; - this->skip_whitespace_count (&nextch); - + ACEXML_Char nextch = this->peek(); switch (nextch) { - case '#': // Mixed element, - if (this->parse_token (ACE_TEXT ("#PCDATA")) < 0) - { - this->report_fatal_error(ACE_TEXT("Expecting keyword `#PCDATA' while defining an element.") ACEXML_ENV_ARG_PARAMETER); - return -1; - } - - this->skip_whitespace_count (&nextch); - - while (nextch != ')') - { - if (this->get () != '|') - { - this->report_fatal_error(ACE_TEXT("Expecting end of Mixed section while defining an element.") ACEXML_ENV_ARG_PARAMETER); - return -1; - } - this->skip_whitespace_count (); - - ACEXML_Char *name = this->read_name (); - // @@ name will be used in the Validator later. - ACE_UNUSED_ARG (name); - ++subelement_number; - // @@ Install Mixed element name into the validator. - this->skip_whitespace_count (&nextch); - } - - if (this->get () != ')' || - (subelement_number && this->get () != '*')) - { - this->report_fatal_error(ACE_TEXT("Expecting closing `)*' or ')' while defining an element.") ACEXML_ENV_ARG_PARAMETER); + case '#': // Mixed element, + if (this->parse_token (ACE_TEXT ("#PCDATA")) < 0) + { + this->fatal_error(ACE_TEXT ("Expecting keyword '#PCDATA'") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + this->check_for_PE_reference (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + nextch = this->get(); + while (nextch == '|') + { + this->check_for_PE_reference (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + ACEXML_Char *name = this->parse_name (); + // @@ name will be used in the Validator later. + ACE_UNUSED_ARG (name); + ++subelement_number; + // @@ Install Mixed element name into the validator. + this->check_for_PE_reference (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + nextch = this->skip_whitespace(); + } + if (nextch != ')' || + (subelement_number && this->get () != '*')) + { + this->fatal_error(ACE_TEXT ("Expecing ')' or ')*' at end of Mixed") + ACE_TEXT (" element") ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + // @@ close the element definition in the validator. + break; + default: + int status = this->parse_child (1 ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + if (status != 0) return -1; - } - // @@ close the element definition in the validator. - break; - default: - int status = this->parse_child (1 ACEXML_ENV_ARG_PARAMETER); - ACEXML_CHECK_RETURN (-1); - if (status != 0) - return -1; } return 0; @@ -1692,272 +1998,1317 @@ ACEXML_Parser::parse_children_definition (ACEXML_ENV_SINGLE_ARG_DECL) int ACEXML_Parser::parse_child (int skip_open_paren ACEXML_ENV_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) { // Conditionally consume the open paren. - if (skip_open_paren == 0 && - this->get () != '(') + if (skip_open_paren == 0 && this->get () != '(') { - this->report_fatal_error(ACE_TEXT("Expecting opening `(' while defining an element.") ACEXML_ENV_ARG_PARAMETER); - return -1; + this->fatal_error(ACE_TEXT ("Expecting '(' at beginning of children") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } ACEXML_Char node_type = 0; ACEXML_Char nextch; do { + this->check_for_PE_reference (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); this->skip_whitespace_count (&nextch); switch (nextch) { - case '(': - this->parse_child (0 ACEXML_ENV_ARG_PARAMETER); - ACEXML_CHECK_RETURN (-1); - break; - default: - // must be an element name here. - ACEXML_Char *subelement = this->read_name (); - if (subelement == 0) - { - this->report_fatal_error(ACE_TEXT("Error reading sub-element name while defining an element.") ACEXML_ENV_ARG_PARAMETER); - return -1; - } - // @@ Inform validator of the new element here. - break; - } + case '(': + this->check_for_PE_reference (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + this->parse_child (0 ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + break; + default: + this->check_for_PE_reference (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + // must be an element name here. + ACEXML_Char *subelement = this->parse_name (); + if (subelement == 0) + { + this->fatal_error(ACE_TEXT ("Invalid subelement name") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + // Check for trailing '?', '*', '+' + nextch = this->peek (); + switch (nextch) + { + case '?': + // @@ Consume the character and inform validator as such, + this->get (); + break; + case '*': + // @@ Consume the character and inform validator as such, + this->get (); + break; + case '+': + // @@ Consume the character and inform validator as such, + this->get (); + break; + default: + break; // not much to do. + } + // @@ Inform validator of the new element here. + break; + } + this->check_for_PE_reference (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); this->skip_whitespace_count (&nextch); switch (nextch) { - case '|': - switch (node_type) - { - case 0: - node_type = '|'; - // @@ inform validator of this new type?? - break; - case '|': - break; - default: - this->report_fatal_error(ACE_TEXT("Expecting `,', `|', or `)' while defining an element.") ACEXML_ENV_ARG_PARAMETER); - return -1; - } - break; - case ',': - switch (node_type) - { - case 0: - node_type = ','; - // @@ inform validator of this new type?? - break; - case ',': - break; - default: - this->report_fatal_error(ACE_TEXT("Expecting `,', `|', or `)'while defining an element.") ACEXML_ENV_ARG_PARAMETER); - return -1; - } - case ')': - break; - default: - this->report_fatal_error(ACE_TEXT("Expecting `,', `|', or `)' while defining an element.") ACEXML_ENV_ARG_PARAMETER); - return -1; + case '|': + switch (node_type) + { + case 0: + node_type = '|'; + // @@ inform validator of this new type?? + break; + case '|': + break; + default: + this->fatal_error (ACE_TEXT ("Expecting `,', `|', or `)' ") + ACE_TEXT ("while defining an element") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + break; + case ',': + switch (node_type) + { + case 0: + node_type = ','; + // @@ inform validator of this new type?? + break; + case ',': + break; + default: + this->fatal_error (ACE_TEXT ("Expecting `,', `|', or `)' ") + ACE_TEXT ("while defining an element") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + break; + case ')': + break; + default: + this->fatal_error (ACE_TEXT ("Expecting `,', `|', or `)' ") + ACE_TEXT ("while defining an element") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } - this->get (); // consume , | or ) + nextch = this->get(); // Consume the `,' or `|' or `)' + if (nextch == ')') + break; + this->check_for_PE_reference (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + this->skip_whitespace_count (&nextch); } while (nextch != ')'); + // Check for trailing '?', '*', '+' nextch = this->peek (); switch (nextch) { - case '?': - // @@ Consume the character and inform validator as such, - this->get (); - break; - case '*': - // @@ Consume the character and inform validator as such, - this->get (); - break; - case '+': - // @@ Consume the character and inform validator as such, + case '?': + // @@ Consume the character and inform validator as such, + this->get (); + break; + case '*': + // @@ Consume the character and inform validator as such, + this->get (); + break; + case '+': + // @@ Consume the character and inform validator as such, + this->get (); + break; + default: + break; // not much to do. + } + return 0; +} + +int +ACEXML_Parser::parse_char_reference (ACEXML_Char *buf, size_t& len) +{ + if (len < 7) // Max size of a CharRef plus terminating '\0' + return -1; + ACEXML_Char ch = this->get(); + if (ch != '#') // Internal error. + return -1; + int hex = 0; + ch = this->peek(); + if (ch == 'x') + { + hex = 1; this->get (); - break; - default: - break; // not much to do. } + size_t i = 0; + int more_digit = 0; + ch = this->get (); + for ( ; i < len && + (this->isNormalDigit (ch) || (hex ? this->isCharRef(ch): 0)); ++i) + { + buf[i] = ch; + ch = this->get(); + ++more_digit; + } + if (ch != ';' || !more_digit) + return -1; + buf[i] = 0; + ACEXML_UCS4 sum = (ACEXML_UCS4) ACE_OS::strtol (buf, 0, (hex ? 16 : 10)); + // [WFC: Legal Character] + if (!this->isChar (sum)) + return -1; + int clen; +#if defined (ACE_USES_WCHAR) // UTF-16 + if ((clen = ACEXML_Transcoder::ucs42utf16 (sum, buf, len)) < 0) + return -1; +#else // or UTF-8 + if ((clen = ACEXML_Transcoder::ucs42utf8 (sum, buf, len)) < 0) + return -1; +#endif + buf [clen] = 0; + len = clen; return 0; } -ACEXML_Char -ACEXML_Parser::skip_whitespace (ACEXML_Char **whitespace) +ACEXML_Char* +ACEXML_Parser::parse_reference_name (void) { ACEXML_Char ch = this->get (); + if (!this->isLetter (ch) && (ch != '_' || ch != ':')) + return 0; + while (ch) { + this->alt_stack_.grow (ch); + ch = this->peek (); + if (!this->isNameChar (ch)) + break; + ch = this->get (); + }; + if (ch != ';') + return 0; + ch = this->get(); + return this->alt_stack_.freeze (); +} + +int +ACEXML_Parser::parse_attvalue (ACEXML_Char *&str ACEXML_ENV_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) +{ + ACEXML_Char quote = this->get (); + if (quote != '\'' && quote != '"') // Not a quoted string. + return -1; + ACEXML_Char ch = this->get (); + while (1) + { + if (ch == quote) + { + ACEXML_Char* temp = this->obstack_.freeze (); + // If the attribute type is not CDATA, then the XML processor + // must further process the normalized attribute value by + // discarding any leading and trailing space (#x20) characters, + // and by replacing sequences of space (#x20) characters by a + // single space (#x20) character. + + // if (atttype != CDATA) { + // ACEXML_Char* start = temp; + // ACEXML_Char* end = temp + ACE_OS::strlen (temp); + // while (*start == '\x20') + // start++; + // if (start == end) // String which is all spaces + // str = start; + // while (*start != 0) + // { + // this->obstack_.grow (*start); + // start++; + // while (*start == '\x20') + // start++; + // } + // str = this->obstack_.freeze(); + // } + str = temp; + return 0; + } + switch (ch) + { + case '&': + if (this->peek () == '#') + { + ACEXML_Char buf[7]; + size_t len = sizeof (buf); + if (this->parse_char_reference (buf, len) != 0) + { + // [WFC: Legal Character] + this->fatal_error (ACE_TEXT ("Invalid CharacterRef") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + for (size_t j = 0; j < len; ++j) + this->obstack_.grow (buf[j]); + } + else + { + this->ref_state_ = ACEXML_ParserInt::IN_ATT_VALUE; + this->parse_entity_reference (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + break; + case '\x20': case '\x0D': case '\x0A': case '\x09': + this->obstack_.grow ('\x20'); + break; + case '<': // [WFC: No < in Attribute Values] + this->fatal_error (ACE_TEXT ("Illegal '<' in AttValue") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + break; + case 0: + this->pop_context (1 ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + break; + default: + this->obstack_.grow (ch); + break; + } + ch = this->get(); + } +} + + - if (this->is_whitespace (ch) == 0) +int +ACEXML_Parser::parse_entity_reference (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) +{ + ACEXML_Char* replace = this->parse_reference_name (); + if (replace == 0) { - if (whitespace != 0) - *whitespace = 0; - return ch; + this->fatal_error (ACE_TEXT ("Invalid Reference name") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); } - do + // [WFC: Parsed Entity] + if (this->unparsed_entities_.resolve_entity (replace)) { + this->fatal_error (ACE_TEXT ("EntityRef refers to unparsed entity") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + // Look in the internal general entities set first. + const ACEXML_Char* entity = this->internal_GE_.resolve_entity(replace); + + // Look in the predefined entities. + if (!entity) { - if (whitespace != 0) - this->obstack_.grow (ch); - ch = this->get (); + entity = this->predef_entities_.resolve_entity (replace); + if (entity) + { + // Special case to return the length in case of predefined entities + this->obstack_.grow (*entity); + return 1; + } + } + + if (!this->validate_) + { + if (this->standalone_) + { + // [WFC: Entity Declared] + this->fatal_error (ACE_TEXT ("Undeclared Entity reference") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + else + { + this->content_handler_->skippedEntity (replace + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + return 0; + } } - while (this->is_whitespace (ch)); - if (whitespace != 0) - *whitespace = this->obstack_.freeze (); + // No match in internal subset + if (!entity + // or No DTDs + && (!(this->internal_dtd_ || this->external_dtd_) + // or Only Internal DTD and no parameter entity references + || (this->internal_dtd_ && !this->external_dtd_ + && !this->has_pe_refs_) + // or Standalone = 'yes' + || this->standalone_)) + { + // [WFC: Entity Declared] + this->fatal_error (ACE_TEXT ("Undeclared Entity reference") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } - return ch; + ACEXML_Char* systemId = 0; + ACEXML_Char* publicId = 0; + if (!entity) + { + if (this->external_GE_.resolve_entity (replace, systemId, publicId) < 0) + { + this->fatal_error (ACE_TEXT ("Undeclared Entity reference") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + if (this->ref_state_ == ACEXML_ParserInt::IN_ATT_VALUE) + { + this->fatal_error (ACE_TEXT ("External EntityRef in Attribute Value") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + this->external_entity_++; + } + + + // [WFC: No Recursion] + ACEXML_Char* ref_name = replace; + int present = this->GE_reference_.insert (ref_name); + if (present == 1 || present == -1) + { + while (this->GE_reference_.pop(ref_name) != -1) + ; + this->fatal_error (ACE_TEXT ("Recursion in resolving entity") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + + if (!this->external_entity_) + { + ACEXML_StrCharStream* str = 0; + ACE_NEW_RETURN (str, ACEXML_StrCharStream, -1); + if (str->open (entity, replace) < 0 + || this->switch_input (str, replace) != 0) + { + this->fatal_error (ACE_TEXT ("Unable to create internal input ") + ACE_TEXT ("stream") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + return 0; + } + else + { + ACEXML_Char* uri = this->normalize_systemid (systemId); + ACE_Auto_Basic_Array_Ptr<ACEXML_Char> cleanup_uri (uri); + ACEXML_InputSource* ip = 0; + if (this->entity_resolver_) + { + ip = this->entity_resolver_->resolveEntity (publicId, + (uri ? uri : systemId) + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + if (ip) + { + if (this->switch_input (ip, (uri ? uri : systemId), + publicId) != 0) + { + this->fatal_error (ACE_TEXT ("Internal Parser Error") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + return 0; + } + } + ACEXML_StreamFactory factory; + ACEXML_CharStream* cstream = factory.create_stream (uri ? uri: systemId); + if (!cstream) { + this->fatal_error (ACE_TEXT ("Invalid input source") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + if (this->switch_input (cstream, systemId, publicId) != 0) + { + this->fatal_error (ACE_TEXT ("Internal Parser Error") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + } + return 0; } int -ACEXML_Parser::skip_whitespace_count (ACEXML_Char *peeky) +ACEXML_Parser::parse_PE_reference (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) { - int wscount = 0; - ACEXML_Char dummy; - ACEXML_Char &forward = (peeky == 0 ? dummy : *peeky); + ACEXML_Char* replace = this->parse_reference_name (); + if (replace == 0) + { + this->fatal_error (ACE_TEXT ("Invalid PEReference name") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + + // Look in the internal general entities set first. + const ACEXML_Char* entity = this->internal_PE_.resolve_entity(replace); + + if (!entity && // No match in internal + (!this->external_dtd_ || // or No External DTDs + this->standalone_)) // or Standalone + { + // [VC: Entity Declared] + this->fatal_error (ACE_TEXT ("Undefined Internal PEReference") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + + ACEXML_Char* systemId = 0; + ACEXML_Char* publicId = 0; + if (!entity && this->validate_) + { + if (this->external_PE_.resolve_entity (replace, systemId, publicId) < 0) + { + this->fatal_error (ACE_TEXT ("Undefined PEReference") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + this->external_entity_++; + } - for (;this->is_whitespace ((forward = this->peek ())); ++wscount) - this->get (); + // [WFC: No Recursion] + ACEXML_Char* ref_name = replace; + int present = this->PE_reference_.insert (ref_name); + if (present == 1 || present == -1) + { + while (this->PE_reference_.pop(ref_name) != -1) + ; + this->fatal_error (ACE_TEXT ("Recursion in resolving entity") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } - return wscount; + if (entity && !this->external_entity_) + { + ACEXML_StrCharStream* sstream = 0; + ACEXML_String str (entity); + if (this->ref_state_ != ACEXML_ParserInt::IN_ENTITY_VALUE) + { + const ACEXML_Char ch = '\x20'; + str = ch + str + ch; + } + // ACE_DEBUG ((LM_DEBUG, + // ACE_TEXT ("Entity is %s\n Replacement Text is : %s\n"), + // replace, str.c_str())); + ACE_NEW_RETURN (sstream, ACEXML_StrCharStream, -1); + if (sstream->open (str.c_str(), replace) < 0 + || this->switch_input (sstream, replace) != 0) + { + this->fatal_error (ACE_TEXT ("Error in switching InputSource") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + return 0; + } + else if (this->external_entity_ && this->validate_) + { + ACEXML_Char* uri = this->normalize_systemid (systemId); + ACE_Auto_Basic_Array_Ptr<ACEXML_Char> cleanup_uri (uri); + ACEXML_InputSource* ip = 0; + if (this->entity_resolver_) + { + ip = this->entity_resolver_->resolveEntity (publicId, + (uri ? uri : systemId) + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + if (ip) + { + if (this->switch_input (ip, (uri ? uri : systemId), publicId) != 0) + { + this->fatal_error (ACE_TEXT ("Error in switching InputSource") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + return 0; + } + else + { + ACEXML_StreamFactory factory; + ACEXML_CharStream* cstream = factory.create_stream (uri ? uri: systemId); + if (!cstream) { + this->fatal_error (ACE_TEXT ("Invalid input source") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + if (this->switch_input (cstream, systemId, publicId) != 0) + { + this->fatal_error (ACE_TEXT ("Error in switching InputSource") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + if (this->ref_state_ == ACEXML_ParserInt::IN_ENTITY_VALUE) + { + ACEXML_Char less, mark; + if (this->peek() == '<') + { + less = this->get(); + if (this->peek() == '?') + { + mark = this->get(); + if (this->peek() == 'x') + { + this->parse_text_decl (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + else + { + this->obstack_.grow (less); + this->obstack_.grow (mark); + } + } + this->obstack_.grow (less); + } + } + return 0; + } + } + this->fatal_error (ACE_TEXT ("Undefined PEReference") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + return -1; } int -ACEXML_Parser::parse_token (const ACEXML_Char* keyword) +ACEXML_Parser::parse_entity_value (ACEXML_Char *&str + ACEXML_ENV_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) { - if (keyword == 0) + ACEXML_ParserInt::ReferenceState temp = this->ref_state_; + ACEXML_Char quote = this->get (); + if (quote != '\'' && quote != '"') // Not a quoted string. return -1; - const ACEXML_Char* ptr = keyword; - ACEXML_Char ch; - for (; *ptr != 0 && ((ch = this->get()) == *ptr); ++ptr) + ACEXML_Char ch = this->get (); + while (1) { - // ACE_DEBUG ((LM_DEBUG, ACE_TEXT ("ch = %c : ptr = %c"), ch, *ptr)); + if (ch == quote) + { + str = this->obstack_.freeze (); + this->ref_state_ = temp; + return 0; + } + switch (ch) + { + case '&': + if (this->peek () == '#') + { + if (!this->external_entity_) + { + ACEXML_Char buf[7]; + size_t len = sizeof (buf); + if (this->parse_char_reference (buf, len) != 0) + { + // [WFC: Legal Character] + this->fatal_error (ACE_TEXT ("Invalid character ") + ACE_TEXT ("reference") + ACEXML_ENV_ARG_PARAMETER); + return -1; + } + for (size_t j = 0; j < len; ++j) + this->obstack_.grow (buf[j]); + break; + } + } + this->obstack_.grow (ch); + break; + case '%': + if (!this->external_entity_) + { + this->ref_state_ = ACEXML_ParserInt::IN_ENTITY_VALUE; + this->parse_PE_reference(ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + break; + } + this->obstack_.grow (ch); + break; + case 0: + this->pop_context (0 ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + break; + default: + this->obstack_.grow (ch); + break; + } + ch = this->get(); } - if (*ptr == 0) - return 0; - else - return -1; } -int -ACEXML_Parser::skip_equal (void) +ACEXML_Char * +ACEXML_Parser::parse_name (ACEXML_Char ch) { - if (this->skip_whitespace (0) != '=') - return -1; + if (ch == 0) + ch = this->get (); + if (!this->isLetter (ch) && ch != '_' && ch != ':') + return 0; + while (ch) { + this->obstack_.grow (ch); + ch = this->peek (); + if (!this->isNameChar (ch)) + break; + ch = this->get (); + }; + return this->obstack_.freeze (); +} - while (this->is_whitespace (this->peek ())) - this->get (); - return 0; +ACEXML_Char* +ACEXML_Parser::parse_nmtoken (ACEXML_Char ch) +{ + if (ch == 0) + ch = this->get (); + if (!this->isNameChar (ch)) + return 0; + while (ch) { + this->obstack_.grow (ch); + ch = this->peek (); + if (!this->isNameChar (ch)) + break; + ch = this->get (); + }; + return this->obstack_.freeze (); } int -ACEXML_Parser::get_quoted_string (ACEXML_Char *&str) +ACEXML_Parser::parse_version_num (ACEXML_Char*& str) { ACEXML_Char quote = this->get (); if (quote != '\'' && quote != '"') // Not a quoted string. return -1; - + int numchars = 0; while (1) { ACEXML_Char ch = this->get (); + if (ch == quote && !numchars) + return -1; + else if (ch == quote) + { + str = this->obstack_.freeze (); + return 0; + } + // [26] VersionNum ::= ([a-zA-Z0-9_.:] | '-')+ + if (ch == '-' || ((ch >= 'a' && ch <= 'z') || + (ch >= 'A' && ch <= 'Z') || + (ch >= '0' && ch <= '9') || + (ch == '_' || ch == '.' || ch == ':'))) + { + this->obstack_.grow (ch); + numchars++; + } + else + return -1; + } +} - // @@ Deoes not handle buffer overflow yet. +int +ACEXML_Parser::parse_system_literal (ACEXML_Char*& str) +{ + const ACEXML_Char quote = this->get(); + if (quote != '\'' && quote != '"') // Not a quoted string. + return -1; + while (1) + { + ACEXML_Char ch = this->get (); if (ch == quote) { str = this->obstack_.freeze (); return 0; } - - const ACEXML_String *replace = 0; - ACEXML_String charval; - ACEXML_Char buffer[6]; - size_t i = 0; - switch (ch) { - case '&': - if (this->peek () == '#') - { - if (this->parse_char_reference (buffer, 6) != 0) - { -// xmlenv.exception (new ACEXML_SAXParseException -// (ACE_TEXT ("CharRef does not resolves to a valid character"))); - return -1; - } - charval.set (buffer, 0); - replace = &charval; - } - else - replace = this->parse_reference (); - - if (replace == 0) - { - // xmlenv.exception (new ACEXML_SAXParseException - // (ACE_TEXT ("Undefined reference"))); - return -1; - } - for (i = 0; i < replace->length (); ++i) - this->obstack_.grow ((*replace)[i]); - // handle reference here. - break; - case 0x0D: // End-of-Line handling - ch = (this->peek () == 0x0A ? this->get () : 0x0A); - // Fall thru... - case 0x0A: - // Fall thru... - default: - this->obstack_.grow (ch); - break; + case '\x00': case '\x01': case '\x02': case '\x03': case '\x04': + case '\x05': case '\x06': case '\x07': case '\x08': case '\x09': + case '\x0A': case '\x0B': case '\x0C': case '\x0D': case '\x0E': + case '\x0F': case '\x10': case '\x11': case '\x12': case '\x13': + case '\x14': case '\x15': case '\x16': case '\x17': case '\x18': + case '\x19': case '\x1A': case '\x1B': case '\x1C': case '\x1D': + case '\x1E': case '\x1F': case '\x7F': case '\x20': case '<': + case '>': case '#': case '%': + ACE_ERROR ((LM_ERROR, + ACE_TEXT ("Invalid char %c in SystemLiteral\n"), ch)); + return -1; + default: + this->obstack_.grow (ch); } } } -ACEXML_Char * -ACEXML_Parser::read_name (ACEXML_Char ch) +int +ACEXML_Parser::parse_pubid_literal (ACEXML_Char*& str) { - if (ch == 0) + const ACEXML_Char quote = this->get(); + if (quote != '\'' && quote != '"') // Not a quoted string. + return -1; + while (1) { - ch = this->get (); - - if (this->is_whitespace (ch)) - // No white space is allowed here. - return 0; + ACEXML_Char ch = this->get (); + if (ch == quote) + { + str = this->obstack_.freeze (); + return 0; + } + else if (this->isPubidChar (ch)) + this->obstack_.grow (ch); + else + return -1; } - else if (this->is_nonname (ch)) - return 0; +} +int +ACEXML_Parser::parse_encname (ACEXML_Char*& str) +{ + const ACEXML_Char quote = this->get (); + if (quote != '\'' && quote != '"') // Not a quoted string. + return -1; + int numchars = 0; while (1) { - this->obstack_.grow (ch); - ch = this->peek (); - if (this->is_nonname (ch)) - break; - ch = this->get (); - }; + ACEXML_Char ch = this->get (); + if (ch == quote && !numchars) + return -1; + else if (ch == quote) + { + str = this->obstack_.freeze (); + return 0; + } + // [81] EncName ::= [A-Za-z] ([A-Za-z0-9._] | '-')* + if (!((ch >= 'a' && ch <= 'z') || (ch >= 'A' && ch <= 'Z')) + && !numchars) + return -1; + if (ch == '-' || ((ch >= 'a' && ch <= 'z') || + (ch >= 'A' && ch <= 'Z') || + (ch >= '0' && ch <= '9') || + (ch == '_' || ch == '.'))) + { + this->obstack_.grow (ch); + numchars++; + } + else + return -1; + } +} - return this->obstack_.freeze (); +int +ACEXML_Parser::parse_sddecl (ACEXML_Char*& str) +{ + ACEXML_Char quote = this->get (); + if (quote != '\'' && quote != '"') // Not a quoted string. + return -1; + int numchars = 0; + while (1) + { + ACEXML_Char ch = this->get (); + if (ch == quote && numchars < 2) + return -1; + else if (ch == quote) + { + str = this->obstack_.freeze (); + return 0; + } + // [32] SDDecl ::= S 'standalone' Eq (("'" ('yes' | 'no') "'") + // | ('"' ('yes' | 'no') '"')) + switch (ch) + { + case 'y': case 'e': case 's': case 'n': case 'o': + this->obstack_.grow (ch); + numchars++; + break; + default: + return -1; + } + } } void -ACEXML_Parser::report_prefix_mapping (const ACEXML_Char* prefix, - const ACEXML_Char* uri, - const ACEXML_Char* name, - int start ACEXML_ENV_ARG_DECL) +ACEXML_Parser::prefix_mapping (const ACEXML_Char* prefix, + const ACEXML_Char* uri, + const ACEXML_Char* name, + int start ACEXML_ENV_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) { if (this->namespaces_) { const ACEXML_Char* temp = (name == 0) ? empty_string : prefix; if (start) { - this->content_handler_->startPrefixMapping (temp, uri ACEXML_ENV_ARG_PARAMETER); + this->content_handler_->startPrefixMapping (temp, uri + ACEXML_ENV_ARG_PARAMETER); ACEXML_CHECK; } else { - this->content_handler_->endPrefixMapping(temp ACEXML_ENV_ARG_PARAMETER); + this->content_handler_->endPrefixMapping(temp + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK; + } + } +} + +int +ACEXML_Parser::switch_input (ACEXML_CharStream* cstream, + const ACEXML_Char* systemId, + const ACEXML_Char* publicId) +{ + ACEXML_InputSource* input = 0; + ACE_NEW_RETURN (input, ACEXML_InputSource (cstream), -1); + return this->switch_input (input, systemId, publicId); +} + +int +ACEXML_Parser::switch_input (ACEXML_InputSource* input, + const ACEXML_Char* systemId, + const ACEXML_Char* publicId) +{ + ACEXML_LocatorImpl* locator = 0; + if (!systemId) + systemId = input->getSystemId(); + ACE_NEW_RETURN (locator, ACEXML_LocatorImpl (systemId, publicId), -1); + ACEXML_Parser_Context* new_context = 0; + ACE_NEW_RETURN (new_context, ACEXML_Parser_Context(input, locator), -1); + if (this->push_context (new_context) != 0) + { + ACE_ERROR ((LM_ERROR, "Unable to switch input streams")); + delete new_context; + return -1; + } + this->current_ = new_context; + this->content_handler_->setDocumentLocator (this->current_->getLocator()); + return 0; +} + +int +ACEXML_Parser::push_context (ACEXML_Parser_Context* context) +{ + if (this->ctx_stack_.push (context) < 0) + { + ACE_ERROR ((LM_ERROR, "Unable to push input source onto the stack")); + return -1; + } + return 0; +} + +int +ACEXML_Parser::pop_context (int GE_ref ACEXML_ENV_ARG_DECL) +{ + int nrelems = this->ctx_stack_.size(); + if (nrelems <= 1) + { + this->fatal_error(ACE_TEXT ("Unexpected end-of-file") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + + ACEXML_Parser_Context* temp = 0; + int retval = this->ctx_stack_.pop (temp); + if (retval != 0) + { + this->fatal_error (ACE_TEXT ("Unable to pop element of the input stack") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + delete temp; + if (this->ctx_stack_.top (this->current_) != 0) + { + this->fatal_error (ACE_TEXT ("Unable to read top element of input stack") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + ACEXML_Char* reference = 0; + if (GE_ref == 1 && this->GE_reference_.size() > 0) + { + if (this->GE_reference_.pop (reference) < 0) + { + this->fatal_error (ACE_TEXT ("Internal Parser Error") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + } + else if (GE_ref == 0 && this->PE_reference_.size() > 0) + { + if (this->PE_reference_.pop (reference) < 0) + { + this->fatal_error (ACE_TEXT ("Internal Parser Error") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + } + nrelems = this->ctx_stack_.size(); + + if (this->external_entity_ && (GE_ref == 0 || GE_ref == 1)) + this->external_entity_--; + + this->content_handler_->setDocumentLocator (this->current_->getLocator()); + + return nrelems; +} + +int +ACEXML_Parser::getFeature (const ACEXML_Char *name ACEXML_ENV_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXNotRecognizedException, + ACEXML_SAXNotSupportedException)) +{ + if (ACE_OS::strcmp (name, ACEXML_Parser::simple_parsing_feature_) == 0) + { + return this->simple_parsing_; + } + else if (ACE_OS::strcmp (name, ACEXML_Parser::namespaces_feature_) == 0) + { + return this->namespaces_; + } + else if (ACE_OS::strcmp (name, + ACEXML_Parser::namespace_prefixes_feature_) == 0) + { + return this->namespace_prefixes_; + } + else if (ACE_OS::strcmp (name, ACEXML_Parser::validation_feature_) == 0) + { + return this->validate_; + } + ACEXML_THROW_RETURN (ACEXML_SAXNotRecognizedException (name), -1); +} + + + +void +ACEXML_Parser::setFeature (const ACEXML_Char *name, + int boolean_value ACEXML_ENV_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXNotRecognizedException, + ACEXML_SAXNotSupportedException)) +{ + if (ACE_OS::strcmp (name, ACEXML_Parser::simple_parsing_feature_) == 0) + { + this->simple_parsing_ = (boolean_value == 0 ? 0 : 1); + return; + } + else if (ACE_OS::strcmp (name, ACEXML_Parser::namespaces_feature_) == 0) + { + this->namespaces_ = (boolean_value == 0 ? 0 : 1); + return; + } + else if (ACE_OS::strcmp (name, + ACEXML_Parser::namespace_prefixes_feature_) == 0) + { + this->namespace_prefixes_ = (boolean_value == 0 ? 0 : 1); + return; + } + else if (ACE_OS::strcmp (name, ACEXML_Parser::validation_feature_) == 0) + { + this->validate_ = (boolean_value == 0 ? 0 : 1); + return; + } + + ACEXML_THROW (ACEXML_SAXNotRecognizedException (name)); +} + +void * +ACEXML_Parser::getProperty (const ACEXML_Char *name ACEXML_ENV_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXNotRecognizedException, + ACEXML_SAXNotSupportedException)) +{ + ACEXML_THROW_RETURN (ACEXML_SAXNotSupportedException (name), 0); +} + +void +ACEXML_Parser::setProperty (const ACEXML_Char *name, + void *value ACEXML_ENV_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXNotRecognizedException, + ACEXML_SAXNotSupportedException)) +{ + ACE_UNUSED_ARG (value); + + ACEXML_THROW (ACEXML_SAXNotSupportedException (name)); +} + +void +ACEXML_Parser::error (const ACEXML_Char* msg ACEXML_ENV_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) +{ + ACEXML_SAXParseException* exception = 0; + ACE_NEW_NORETURN (exception, ACEXML_SAXParseException (msg)); + if (this->error_handler_) + this->error_handler_->error (*exception ACEXML_ENV_ARG_PARAMETER); + else + ACEXML_ENV_RAISE (exception); + return; +} + +void +ACEXML_Parser::warning (const ACEXML_Char* msg ACEXML_ENV_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) +{ + ACEXML_SAXParseException* exception = 0; + ACE_NEW_NORETURN (exception, ACEXML_SAXParseException (msg)); + if (this->error_handler_) + this->error_handler_->warning (*exception ACEXML_ENV_ARG_PARAMETER); + delete exception; + return; +} + +void +ACEXML_Parser::fatal_error (const ACEXML_Char* msg ACEXML_ENV_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) +{ + ACEXML_SAXParseException* exception = 0; + ACE_NEW_NORETURN (exception, ACEXML_SAXParseException (msg)); + if (this->error_handler_) + this->error_handler_->fatalError (*exception ACEXML_ENV_ARG_PARAMETER); + ACEXML_ENV_RAISE (exception); + return; +} + +void +ACEXML_Parser::parse_version_info (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) +{ + ACEXML_Char* astring; + if (this->parse_token (ACE_TEXT("ersion")) < 0 + || this->skip_equal () != 0 + || this->parse_version_num (astring) != 0) + { + this->fatal_error (ACE_TEXT ("Invalid VersionInfo specification") + ACEXML_ENV_ARG_PARAMETER); + return; + } + if (ACE_OS::strcmp (astring, ACE_TEXT ("1.0")) != 0) + { + this->fatal_error (ACE_TEXT ("ACEXML Parser supports XML version 1.0 ") + ACE_TEXT ("documents only") ACEXML_ENV_ARG_PARAMETER); + return; + } +} + +void +ACEXML_Parser::parse_encoding_decl (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) +{ + ACEXML_Char* astring; + if ((this->parse_token (ACE_TEXT("ncoding")) < 0) + || this->skip_equal () != 0 + || this->parse_encname (astring) != 0) + { + this->fatal_error (ACE_TEXT ("Invalid EncodingDecl specification") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK; + } + const ACEXML_Char* encoding = this->current_->getInputSource()->getEncoding(); + if (ACE_OS::strcmp (astring, encoding) != 0) + { + ACE_ERROR ((LM_ERROR, ACE_TEXT ("Detected Encoding is %s ") + ACE_TEXT (": Declared Encoding is %s\n"), + encoding, astring)); + this->warning (ACE_TEXT ("Declared encoding differs from detected ") + ACE_TEXT ("encoding") ACEXML_ENV_ARG_PARAMETER); + } +} + +int +ACEXML_Parser::parse_text_decl (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) +{ + // Read xml + if (this->parse_token (ACE_TEXT("xml")) < 0) + { + this->fatal_error(ACE_TEXT ("Expecting keyword 'xml' in TextDecl") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + + ACEXML_Char fwd = this->skip_whitespace(); + // Read version + if (fwd == 'v') + { + this->parse_version_info (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + fwd = this->skip_whitespace(); + } + + if (fwd == 'e') + { + this->parse_encoding_decl (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + fwd = this->skip_whitespace(); + } + else + { + this->fatal_error (ACE_TEXT ("Missing encodingDecl in TextDecl") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + + if (fwd == '?' && this->get() == '>') + return 0; + // All the rules fail. So return an error. + this->fatal_error (ACE_TEXT ("Invalid TextDecl") ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + return -1; +} + +void +ACEXML_Parser::parse_xml_decl (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) +{ + // Read <?xml + if (this->parse_token (ACE_TEXT("xml")) < 0) + { + this->fatal_error(ACE_TEXT ("Expecting keyword xml in XMLDecl") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK; + } + + ACEXML_Char fwd = this->skip_whitespace(); + + // Read version + if (fwd != 'v') + { + this->fatal_error (ACE_TEXT ("Expecting VersionInfo declaration") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK; + } + + this->parse_version_info (ACEXML_ENV_SINGLE_ARG_PARAMETER); + ACEXML_CHECK; + + fwd = this->skip_whitespace(); + if (fwd != '?') + { + if (fwd == 'e') + { + this->parse_encoding_decl (ACEXML_ENV_SINGLE_ARG_PARAMETER); ACEXML_CHECK; + fwd = this->skip_whitespace(); + } + if (fwd == 's') + { + ACEXML_Char* astring; + if ((this->parse_token (ACE_TEXT("tandalone")) == 0) && + this->skip_equal () == 0 && + this->parse_sddecl (astring) == 0) + { + if (ACE_OS::strcmp (astring, ACE_TEXT ("yes")) == 0) + this->standalone_ = 1; + fwd = this->skip_whitespace(); + } + } + } + if (fwd == '?' && this->get() == '>') + return; + // All the rules fail. So return an error. + this->fatal_error (ACE_TEXT ("Invalid XMLDecl declaration") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK; +} + +int +ACEXML_Parser::parse_comment (void) +{ + int state = 0; + + if (this->get () != '-' || // Skip the opening "<!--" + this->get () != '-' || // completely. + this->get () == '-') // and at least something not '-'. + return -1; + + while (state < 3) + // Waiting for the trailing three character '-->'. Notice that + // according to the spec, '--->' is not a valid closing comment + // sequence. But we'll let it pass anyway. + { + ACEXML_Char fwd = this->get (); + if ((fwd == '-' && state < 2) || + (fwd == '>' && state == 2)) + state += 1; + else + state = 0; // Reset parse state. + } + return 0; +} + +int +ACEXML_Parser::parse_processing_instruction (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)) +{ + const ACEXML_Char *pitarget = this->parse_name (); + ACEXML_Char *instruction = 0; + + if (!ACE_OS::strcasecmp (ACE_TEXT ("xml"), pitarget)) + { + // Invalid PITarget name. + this->fatal_error(ACE_TEXT ("PI can't have 'xml' in PITarget") + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + } + + int state = 0; + + ACEXML_Char ch = this->skip_whitespace(); + while (state < 2) + { + switch (ch) + { + case '?': + if (state == 0) + state = 1; + break; + case '>': + if (state == 1) + { + instruction = this->obstack_.freeze (); + this->content_handler_->processingInstruction (pitarget, + instruction + ACEXML_ENV_ARG_PARAMETER); + ACEXML_CHECK_RETURN (-1); + this->obstack_.unwind (ACE_const_cast (ACEXML_Char*, pitarget)); + return 0; + } + break; + case 0x0A: + // Fall thru... + default: + if (state == 1) + this->obstack_.grow ('?'); + this->obstack_.grow (ch); + state = 0; } + ch = this->get (); } + return -1; +} + +void +ACEXML_Parser::reset (void) +{ + this->doctype_ = 0; + if (this->ctx_stack_.pop (this->current_) == -1) + ACE_ERROR ((LM_ERROR, + ACE_TEXT ("Mismatched push/pop of Context stack"))); + delete this->current_->getLocator(); + this->current_ = 0; + + ACEXML_Char* temp = 0; + while (this->GE_reference_.pop (temp) != -1) + ; + while (this->PE_reference_.pop (temp) != -1) + ; + this->obstack_.release(); + this->alt_stack_.release(); + this->xml_namespace_.reset(); + this->nested_namespace_ = 0; + this->internal_GE_.reset(); + this->external_GE_.reset(); + this->unparsed_entities_.reset(); + this->predef_entities_.reset(); + this->internal_PE_.reset(); + this->external_PE_.reset(); + this->notations_.reset(); + this->ref_state_ = ACEXML_ParserInt::INVALID; + this->external_subset_ = 0; + this->external_entity_ = 0; + this->has_pe_refs_ = 0; + this->standalone_ = 0; + this->external_dtd_ = 0; + this->internal_dtd_ = 0; } diff --git a/ACEXML/parser/parser/Parser.h b/ACEXML/parser/parser/Parser.h index e45e290ca79..fac5a3ba04c 100644 --- a/ACEXML/parser/parser/Parser.h +++ b/ACEXML/parser/parser/Parser.h @@ -7,6 +7,7 @@ * $Id$ * * @author Nanbor Wang <nanbor@cs.wustl.edu> + * @author Krishnakumar B <kitty@cs.wustl.edu> */ //============================================================================= @@ -28,9 +29,12 @@ #include "ace/Functor.h" #include "ace/SString.h" #include "ace/Hash_Map_Manager.h" +#include "ace/Unbounded_Set.h" #include "ace/Containers_T.h" #include "ace/Auto_Ptr.h" #include "ACEXML/parser/parser/Entity_Manager.h" +#include "ACEXML/parser/parser/ParserInternals.h" +#include "ACEXML/parser/parser/ParserContext.h" /** * @class ACEXML_Parser Parser.h "ACEXML/parser/parser/Parser.h" @@ -47,7 +51,14 @@ public: /// Destructor. virtual ~ACEXML_Parser (void); - /* + /** + * Initialize the parser state. + * + * @retval 0 if parser was initialized correctly else -1. + */ + int initialize (ACEXML_InputSource* input); + + /** * Return the current content handler. */ virtual ACEXML_ContentHandler *getContentHandler (void) const; @@ -132,80 +143,41 @@ public: */ virtual void setErrorHandler (ACEXML_ErrorHandler *handler); - // *** Helper functions for parsing XML - /** - * Skip any whitespaces encountered until the first non-whitespace - * character is encountered and consumed from the current input - * CharStream. - * - * @param whitespace Return a pointer to the string of skipped - * whitespace after proper conversion. Null if there's no - * whitespace found. - * - * @return The first none-white space characters (which will be - * consumed from the CharStream.) If no whitespace is found, it - * returns 0. - * - * @sa skip_whitespace_count - */ - ACEXML_Char skip_whitespace (ACEXML_Char **whitespace); +protected: /** - * Skip any whitespaces encountered until the first non-whitespace - * character. The first non-whitespace character is not consumed. - * This method does peek into the input CharStream and therefore - * is more expensive than @ref skip_whitespace. - * - * @param peek If non-null, @a peek points to a ACEXML_Char where - * skip_whitespace_count stores the first non-whitespace - * character it sees (character is not removed from the stream.) - * - * @return The number of whitespace characters consumed. - * - * @sa skip_whitespace + * Parse XML Prolog. */ - int skip_whitespace_count (ACEXML_Char *peek = 0); + void parse_xml_prolog (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); /** - * Check if a character @a c is a whitespace. + * Parse VersionInfo declaration. * - * @retval 1 if @a c is a valid white space character. 0 otherwise. */ - int is_whitespace (ACEXML_Char c); + void parse_version_info (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); /** - * Check if a character @a c is a whitespace or '='. + * Parse a EncodingDecl declaration. * - * @retval 1 if true, 0 otherwise. */ - int is_whitespace_or_equal (ACEXML_Char c); + void parse_encoding_decl (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); /** - * Check if a character @a c is a valid character for nonterminal NAME. + * Parse a XMLDecl declaration. * - * @retval 1 if true, 0 otherwise. */ - int is_nonname (ACEXML_Char c); + void parse_xml_decl (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); /** - * Skip an equal sign. - * - * @retval 0 when succeeds, -1 if no equal sign is found. + * Parse a TextDecl declaration. */ - int skip_equal (void); - - /** - * Get a quoted string. Quoted strings are used to specify - * attribute values and this routine will replace character and - * entity references on-the-fly. Parameter entities are not allowed - * (or replaced) in this function. (But regular entities are.) - * - * @param str returns the un-quoted string. - * - * @retval 0 on success, -1 otherwise. - */ - int get_quoted_string (ACEXML_Char *&str); + int parse_text_decl (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); /** * Parse a PI statement. The first character encountered @@ -213,33 +185,15 @@ public: * * @retval 0 on success, -1 otherwise. */ - int parse_processing_instruction (ACEXML_ENV_SINGLE_ARG_DECL); - - /** - * Skip over a comment. The first character encountered - * should always be the first '-' in the comment prefix - * "@<@!--". - */ - int grok_comment (); - - /** - * Read a name from the input CharStream (until white space). - * If @a ch @!= 0, then we have already consumed the first name - * character from the input CharStream, otherwise, read_name - * will use this->get() to acquire the initial character. - * - * @return A pointer to the string in the obstack, 0 if it's not - * a valid name. - */ - ACEXML_Char *read_name (ACEXML_Char ch = 0); + int parse_processing_instruction (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); /** * Parse the DOCTYPE declaration. The first character encountered * should always be 'D' in doctype prefix: "@<@!DOCTYPE". */ int parse_doctypedecl (ACEXML_ENV_SINGLE_ARG_DECL) - ACE_THROW_SPEC ((ACEXML_SAXException)) - ; + ACE_THROW_SPEC ((ACEXML_SAXException)); /** * Parse an XML element. The first character encountered should @@ -255,35 +209,39 @@ public: * can be used in a validator. */ void parse_element (int is_root ACEXML_ENV_ARG_DECL) - ACE_THROW_SPEC ((ACEXML_SAXException)) - ; + ACE_THROW_SPEC ((ACEXML_SAXException)); /** - * Parse XML Prolog. + * Parse a content declaration. + * */ - void parse_xml_prolog (ACEXML_ENV_SINGLE_ARG_DECL) + int parse_content (const ACEXML_Char* startname, const ACEXML_Char* ns_uri, + const ACEXML_Char* ns_lname + ACEXML_ENV_ARG_DECL) ACE_THROW_SPEC ((ACEXML_SAXException)); - /** * Parse a character reference, i.e., " " or "". The first * character encountered should be the '#' char. * * @param buf points to a character buffer for the result. - * @param len specifies the capacities of the buffer. + * + * @param len In/out argument which initially specifies the size of the + * buffer and is later set to the no. of characters in the reference. * * @retval 0 on success and -1 otherwise. */ - int parse_char_reference (ACEXML_Char *buf, size_t len); + int parse_char_reference (ACEXML_Char *buf, size_t& len); /** - * Parse an entity reference, i.e., "&". The first character - * encountered should be the character following '&'. + * Parse a reference name, i.e., foo in "&foo;" or "%foo;". The first + * character encountered should be the character following '&' or '%'. + * Effectively the same as @sa parse_name but we don't use the parser's + * obstack. Caller is responsible for deleting the memory. * - * @return A pointer to the resolved const ACEXML_String if success - * (previously defined), 0 otherwise. + * @retval A pointer to name of reference, 0 otherwise. */ - const ACEXML_String *parse_reference (void); + ACEXML_Char* parse_reference_name (void); /** * Parse a CDATA section. The first character should always be the first @@ -292,13 +250,21 @@ public: * @retval 0 on success. * @retval -1 if fail. */ - int parse_cdata (ACEXML_ENV_SINGLE_ARG_DECL); + int parse_cdata (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); /** * Parse a "markupdecl" section, this includes both "markupdecl" and * "DeclSep" sections in XML specification */ - int parse_internal_dtd (ACEXML_ENV_SINGLE_ARG_DECL); + int parse_internal_dtd (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); + + /** + * Skip over a comment. The first character encountered should always be + * the first '-' in the comment prefix "@<@!--". + */ + int parse_comment (void); /** * Parse an "ELEMENT" decl. The first character this method @@ -307,7 +273,8 @@ public: * * @retval 0 on success, -1 otherwise. */ - int parse_element_decl (ACEXML_ENV_SINGLE_ARG_DECL); + int parse_element_decl (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); /** * Parse an "ENTITY" decl. The first character this method expects @@ -315,7 +282,8 @@ public: * * @retval 0 on success, -1 otherwise. */ - int parse_entity_decl (ACEXML_ENV_SINGLE_ARG_DECL); + int parse_entity_decl (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); /** * Parse an "ATTLIST" decl. Thse first character this method @@ -324,7 +292,15 @@ public: * * @retval 0 on success, -1 otherwise. */ - int parse_attlist_decl (ACEXML_ENV_SINGLE_ARG_DECL); + int parse_attlist_decl (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); + + /** + * Parse a AttType declaration. + * + */ + int parse_atttype (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); /** *Parse a "NOTATION" decl. The first character this method @@ -333,7 +309,8 @@ public: * * @retval 0 on success, -1 otherwise. */ - int parse_notation_decl (ACEXML_ENV_SINGLE_ARG_DECL); + int parse_notation_decl (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); /** * Parse an ExternalID or a reference to PUBLIC ExternalID. @@ -355,8 +332,81 @@ public: * * @retval 0 on success, -1 otherwise. */ - int parse_external_id_and_ref (ACEXML_Char *&publicId, - ACEXML_Char *&systemId ACEXML_ENV_ARG_DECL); + int parse_external_id (ACEXML_Char *&publicId, ACEXML_Char *&systemId + ACEXML_ENV_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); + + /** + * Parse an external DTD. + * + */ + int parse_external_dtd (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); + + /** + * Parse an external subset. This does the actual parsing of an external + * subset and is called by @sa parse_external_dtd. + * + */ + int parse_external_subset (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); + + /** + * Parse a markupDecl section. + * + */ + int parse_markup_decl (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); + + /** + * Parse a conditionalSect declaration. + * + */ + int parse_conditional_section (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); + + /** + * Parse a includeSect declaration. + * + */ + int parse_includesect (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); + + /** + * + * Parse a ignoreSect declaration. + */ + int parse_ignoresect (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); + + /** + * Parse a PEReference. + * + */ + int parse_PE_reference (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); + + /** + * Parse a Reference. + * + */ + int parse_entity_reference (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); + + /** + * Parse an entityValue. + * + */ + int parse_entity_value (ACEXML_Char *&str ACEXML_ENV_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); + + /** + * Parse a DefaultDecl specification. + * + */ + int parse_defaultdecl (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); + /** * Parse the "children" and "Mixed" non-terminals in contentspec. @@ -366,7 +416,8 @@ public: * * @retval 0 on success, -1 otherwise. */ - int parse_children_definition (ACEXML_ENV_SINGLE_ARG_DECL); + int parse_children_definition (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); /** * Parse a @c cp non-terminal. @c cp can either be a @c seq or a @c choice. @@ -378,81 +429,259 @@ public: * * @retval 0 on success, -1 otherwise. */ - int parse_child (int skip_open_paren ACEXML_ENV_ARG_DECL); + int parse_child (int skip_open_paren ACEXML_ENV_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); -protected: - /// Get a character. - ACEXML_Char get (void); + /** + * Parse a name from the input CharStream. If @a ch @!= 0, then we have + * already consumed the first name character from the input CharStream, + * otherwise, parse_name will use this->get() to acquire the initial + * character. + * + * @return A pointer to the string in the obstack, 0 if it's not a + * valid name. + */ + ACEXML_Char *parse_name (ACEXML_Char ch = 0); - /// Peek a character. - ACEXML_Char peek (void); + /** + * Parse a NMTOKEN from the input stream. + * + * @return A pointer to the string in the obstack, 0 if it's not a valid + * NMTOKEN. + */ + ACEXML_Char* parse_nmtoken (ACEXML_Char ch = 0); /** - * Check if more data can be added to a character buffer in obstack. - * If not, the existing data in the buffer will be cleared out by - * freezing the segment and pass it out thru a content_handler_->characters () - * call. @a counter records the length of the existing data in - * obstack. + * Parse the version string in an XML Prolog section. + * + * @param str String containing the version number if successful. + * @return 0 if the string was read successfully, 0 otherwise. */ - int try_grow_cdata (size_t size, size_t &len ACEXML_ENV_ARG_DECL); + int parse_version (ACEXML_Char*& str); - // Feature names: + /** + * Parse the version number in a VersionInfo declaration. + */ + int parse_version_num (ACEXML_Char*& str); /** - * \addtogroup acexml_parser_features - * @{ + * Parse the encoding name in an XML Prolog section. + * + * @param str String containing the encoding name if successful. + * @return 0 if the string was read successfully, 0 otherwise. */ + int parse_encname (ACEXML_Char*& str); /** - * @var simple_parsing_feature_ + * Parse a SDDecl string. * - * This constant string defines the name of "simple XML parsing" - * feature. When this feature is enabled, ACEXML parser is allowed - * to parse a simple XML stream without mandated XML prolog - * and no DTD defintion. + * @param str String containing the encoding name if successful. + * @return 0 if the string was read successfully, -1 otherwise. */ - static const ACEXML_Char simple_parsing_feature_[]; + int parse_sddecl (ACEXML_Char*& str); /** - * @var namespaces_feature_ + * Parse an attribute name. * - * This constant string defines the SAX XML Namespace feature. When this - * feature is enabled, ACEXML parser allows access by namespace qualified - * names. + * @retval str String containing the value of the attribute name + * if successful. + * @retval 0 otherwise. */ - static const ACEXML_Char namespaces_feature_[]; + ACEXML_Char* parse_attname (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); /** - * @var namespace_prefixes_feature_ + * Parse an attribute value. * - * This constant string defines the SAX XML Namespace prefixes feature. - * Normally the list of attributes returned by the parser will not - * contain attributes used as namespace declarations (xmlns*). When this - * feature is enabled, the list of attributes contains the namespace - * declarations also. + * @param str String containing the value of the attribute if successful. + * @return 0 if attribute value was read successfully, -1 otherwise. */ - static const ACEXML_Char namespace_prefixes_feature_[]; + int parse_attvalue (ACEXML_Char*& str ACEXML_ENV_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); - /* @} */ + /** + * Parse a tokenized type attribute. + * + * @return 0 if attribute type was read successfully, -1 otherwise. + */ + int parse_tokenized_type (ACEXML_ENV_SINGLE_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); + + /** + * Parse a SystemLiteral. + * + * @param str String containing the SystemLiteral if successful. + * @return 0 if the string was read successfully, 0 otherwise. + */ + int parse_system_literal (ACEXML_Char*& str); + + /** + * Parse a PubidLiteral. + * + * @param str String containing the PubidLiteral if successful. + * @return 0 if the string was read successfully, 0 otherwise. + */ + int parse_pubid_literal (ACEXML_Char*& str); + + /** + * Check if a character @a c is a whitespace. + * + * @retval 1 if @a c is a valid white space character. 0 otherwise. + */ + int is_whitespace (const ACEXML_Char c) const; + + /** + * Check if a character @a c is a valid Char. + * + * @retval 1 if @a c is a valid character. 0 otherwise. + */ + int isChar (ACEXML_UCS4 c) const; + + /** + * Check if a character @a c is a valid CharRef character. + * + * @retval 1 if @a c is a valid character reference character, 0 otherwise. + */ + int isCharRef (const ACEXML_Char c) const; + + /** + * Check if a character @a c is a BaseChar. + * + * @retval 1 if @a c is a valid BaseChar character, 0 otherwise. + */ + int isBasechar (const ACEXML_Char c) const; + + /** + * Check if a character @a c is a Ideographic. + * + * @retval 1 if @a c is a valid Ideographic character, 0 otherwise. + */ + int isIdeographic (const ACEXML_Char c) const; + + /** + * Check if a character @a c is a CombiningChar. + * + * @retval 1 if @a c is a valid CombiningChar character, 0 otherwise. + */ + int isCombiningchar (const ACEXML_Char c) const; + + /** + * Check if a character @a c is a Digit. + * + * @retval 1 if @a c is a valid Digit character, 0 otherwise. + */ + int isDigit (const ACEXML_Char c) const; + + /** + * Check if a character @a c is an Extender. + * + * @retval 1 if @a c is a valid Extender character, 0 otherwise. + */ + int isExtender (const ACEXML_Char c) const; + + /** + * Check if a character @a c is a Letter. + * + * @retval 1 if @a c is a valid Letter character, 0 otherwise. + */ + int isLetter (const ACEXML_Char c) const; + + /** + * Check if a character is an acceptable NameChar. + * + * @retval 1 if @a c is a valid NameChar character, 0 otherwise. + */ + int isNameChar (const ACEXML_Char c) const; + + /** + * Check if a character is a PubidChar. + * + * @retval 1 if @a c is a valid PubidChar character, 0 otherwise. + */ + int isPubidChar (const ACEXML_Char c) const; + + /// Get a character. + virtual ACEXML_Char get (void); + + /// Peek a character. + virtual ACEXML_Char peek (void); private: + + // *** Helper functions for parsing XML + + /** + * Skip any whitespaces encountered until the first non-whitespace + * character is encountered. + * + * @return The next non-whitespace character from the CharStream. + * + * @sa skip_whitespace_count + */ + ACEXML_Char skip_whitespace (void); + + /** + * Skip any whitespaces encountered until the first non-whitespace + * character. The first non-whitespace character is not consumed. + * This method does peek into the input CharStream and therefore + * is more expensive than @ref skip_whitespace. + * + * @param peek If non-null, @a peek points to a ACEXML_Char where + * skip_whitespace_count stores the first non-whitespace + * character it sees (character is not removed from the stream.) + * + * @return The number of whitespace characters consumed. + * + * @sa skip_whitespace + */ + int skip_whitespace_count (ACEXML_Char *peek = 0); + + /** + * Skip an equal sign. + * + * @retval 0 when succeeds, -1 if no equal sign is found. + */ + int skip_equal (void); + + /** + * Get a quoted string. Quoted strings are used to specify + * attribute values and this routine will replace character and + * entity references on-the-fly. Parameter entities are not allowed + * (or replaced) in this function. (But regular entities are.) + * + * @param str returns the un-quoted string. + * + * @retval 0 on success, -1 otherwise. + */ + int get_quoted_string (ACEXML_Char *&str); + + /** + * Check if a character @a c is a Digit. + * + * @retval 1 if @a c is a valid Digit character, 0 otherwise. + */ + int isNormalDigit (const ACEXML_Char c) const; + /** * Dispatch errors to ErrorHandler. * */ - void report_error (const ACEXML_Char* message ACEXML_ENV_ARG_DECL); + void error (const ACEXML_Char* msg ACEXML_ENV_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); /** * Dispatch warnings to ErrorHandler. * */ - void report_warning (const ACEXML_Char* message ACEXML_ENV_ARG_DECL); + void warning (const ACEXML_Char* msg ACEXML_ENV_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); /** * Dispatch fatal errors to ErrorHandler. * */ - void report_fatal_error (const ACEXML_Char* message ACEXML_ENV_ARG_DECL); + void fatal_error (const ACEXML_Char* msg ACEXML_ENV_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); /** * Dispatch prefix mapping calls to the ContentHandler. @@ -462,15 +691,112 @@ private: * @param name Local name * @param start 1 => startPrefixMapping 0 => endPrefixMapping */ - void report_prefix_mapping (const ACEXML_Char* prefix, + void prefix_mapping (const ACEXML_Char* prefix, const ACEXML_Char* uri, const ACEXML_Char* name, - int start ACEXML_ENV_ARG_DECL); + int start ACEXML_ENV_ARG_DECL) + ACE_THROW_SPEC ((ACEXML_SAXException)); /** * Parse a keyword. */ int parse_token (const ACEXML_Char* keyword); + /** + * Push the current context on to the stack. + * + */ + int push_context (ACEXML_Parser_Context* context); + + /** + * Pop the top element in the stack and replace current context with that. + */ + int pop_context (int GE_ref ACEXML_ENV_ARG_DECL); + + /** + * Create a new ACEXML_CharStream from @a systemId and @a publicId and + * replace the current input stream with the newly created stream. + */ + virtual int switch_input (ACEXML_CharStream* cstream, + const ACEXML_Char* systemId, + const ACEXML_Char* publicId = 0); + /** + * Create a new ACEXML_InputSource from @a systemId and @a publicId and + * replace the current input source with the newly created InputSource. + */ + virtual int switch_input (ACEXML_InputSource* input, + const ACEXML_Char* systemId, + const ACEXML_Char* publicId = 0); + + /** + * Check for a parameter entity reference. This is used to check for the + * occurence of a PE Reference withing markupDecl. Additionally this + * function consumes any leading or trailing whitespace around the PE + * Reference. + * + * @retval Number of whitespace characters skipped. + */ + int check_for_PE_reference (ACEXML_ENV_SINGLE_ARG_DECL); + + /** + * Reset the parser state. + * + */ + void reset (void); + + /** + * Very trivial, non-conformant normalization of a systemid. + * + */ + ACEXML_Char* normalize_systemid (const ACEXML_Char* systemId); + + // Feature names: + + /** + * \addtogroup acexml_parser_features + * @{ + */ + + /** + * @var simple_parsing_feature_ + * + * This constant string defines the name of "simple XML parsing" + * feature. When this feature is enabled, ACEXML parser is allowed + * to parse a simple XML stream without mandated XML prolog + * and no DTD defintion. + */ + static const ACEXML_Char simple_parsing_feature_[]; + + /** + * @var namespaces_feature_ + * + * This constant string defines the SAX XML Namespace feature. When this + * feature is enabled, ACEXML parser allows access by namespace qualified + * names. + */ + static const ACEXML_Char namespaces_feature_[]; + + /** + * @var namespace_prefixes_feature_ + * + * This constant string defines the SAX XML Namespace prefixes feature. + * Normally the list of attributes returned by the parser will not + * contain attributes used as namespace declarations (xmlns*). When this + * feature is enabled, the list of attributes contains the namespace + * declarations also. + */ + static const ACEXML_Char namespace_prefixes_feature_[]; + + /** + * @var validation_feature_ + * + * This constant string defines the SAX XML Validation feature. When + * this feature is enabled, the parser validates the document in + * addition to checking for well-formedness. + */ + static const ACEXML_Char validation_feature_[]; + + /* @} */ + /// Keeping track of the handlers. We do not manage the memory for /// handlers. ACEXML_DTDHandler *dtd_handler_; @@ -478,31 +804,94 @@ private: ACEXML_ContentHandler *content_handler_; ACEXML_ErrorHandler *error_handler_; - /// @@ Feature and properties management structure here. - /// Current input char stream. - ACEXML_CharStream *instream_; - - /// My doctype, if any. + /// Document Type ACEXML_Char *doctype_; - /// External DTD System Literal, if any. - ACEXML_Char *dtd_system_; + /// Current parser context + ACEXML_Parser_Context* current_; + + /// Stack used to hold the Parser_Context + ACE_Unbounded_Stack<ACEXML_Parser_Context*> ctx_stack_; + + /* + * The following two are essentially chains of references and is used by + * the parser to determine if there is any recursion. We keep two of + * these one for general entities and one for parameter entities, as they + * both fall under different namespaces. + * + */ + /// Set used to hold the general entity references that are active. + ACE_Unbounded_Stack<ACEXML_Char*> GE_reference_; - /// External DTD Public Literal, if any. - ACEXML_Char *dtd_public_; + /// Set used to hold the parameter entity references that are active. + ACE_Unbounded_Stack<ACEXML_Char*> PE_reference_; + /// Obstack used by the parser to hold all the strings parsed ACE_Obstack_T<ACEXML_Char> obstack_; + /// Alternative obstack used to hold any strings when the original is in use + ACE_Obstack_T<ACEXML_Char> alt_stack_; + + /// Namespace stack used by the parser to implement support for Namespaces ACEXML_NamespaceSupport xml_namespace_; - ACEXML_Entity_Manager entities_; + /// T => We are processing a nested namespace + int nested_namespace_; + + /// Set of internal parsed general entities in the document + ACEXML_Entity_Manager internal_GE_; + + /// Set of external parsed general entities in the document + ACEXML_Entity_Manager external_GE_; + + /// Set of unparsed entities in the document + ACEXML_Entity_Manager unparsed_entities_; + + /// Set of predefined entities used by the parser + ACEXML_Entity_Manager predef_entities_; + + /// Set of internal parsed parameter entities in the document + ACEXML_Entity_Manager internal_PE_; - // Locator - ACEXML_LocatorImpl locator_; + /// Set of external parsed parameter entities in the document + ACEXML_Entity_Manager external_PE_; - // Feature flags & + /// Set of notations declared in the document + ACEXML_Entity_Manager notations_; + + /// State of the parser when it encounters a reference. + ACEXML_ParserInt::ReferenceState ref_state_; + + /// T => We are parsing an external subset + int external_subset_; + + /// T => We are parsing an external entity value + int external_entity_; + + /// T => Internal DTD has parameter entity references + int has_pe_refs_; + + /// If set, the document is a standalone XML document + int standalone_; + + /// If set, the document has an external DTD subset + int external_dtd_; + + /// If set, the document has an internal DTD + int internal_dtd_; + + /// Feature flags + /// If set, the parser should parse a document without a prolog int simple_parsing_; + + /// If set, the parser should also validate + int validate_; + + /// If set, the parser should allow access by namespace qualified names. int namespaces_; + + /// If set, the parser should include namespace declarations in the list + /// of attributes of an element. int namespace_prefixes_; }; diff --git a/ACEXML/parser/parser/Parser.i b/ACEXML/parser/parser/Parser.i index c346c99471d..dd6231c8a90 100644 --- a/ACEXML/parser/parser/Parser.i +++ b/ACEXML/parser/parser/Parser.i @@ -57,49 +57,113 @@ ACEXML_Parser::setErrorHandler (ACEXML_ErrorHandler *handler) } ACEXML_INLINE int -ACEXML_Parser::is_whitespace (ACEXML_Char c) +ACEXML_Parser::isChar (const ACEXML_UCS4 c) const { - switch (c) + return (c == 0x9 || c == 0xA || c == 0xD || + c >= 0x20 && c <= 0xD7FF || + c >= 0xE000 && c <= 0xFFFD || + c >= 0x10000 && c <= 0x10FFFF); +} + +ACEXML_INLINE int +ACEXML_Parser::isCharRef (const ACEXML_Char c) const { - case 0xa: - case 0x20: - case 0x9: - case 0xd: - return 1; - default: + return ((c >= 'a' && c <= 'f') || + (c >= 'A' && c <= 'F')); +} + +ACEXML_INLINE int +ACEXML_Parser::isNormalDigit (const ACEXML_Char c) const +{ + return (c >= '\x30' && c <= '\x39'); +} + +ACEXML_INLINE int +ACEXML_Parser::isBasechar (const ACEXML_Char c) const +{ +#if defined (ACE_USES_WCHAR) + return ACEXML_ParserInt::isBasechar_i (c); +#else + return ACEXML_ParserInt::base_char_table_[c]; +#endif /* ACE_USES_WCHAR */ +} + +ACEXML_INLINE int +ACEXML_Parser::isIdeographic (const ACEXML_Char c) const +{ +#if defined (ACE_USES_WCHAR) + return ACEXML_ParserInt::isIdeographic_i (c); +#else + ACE_UNUSED_ARG (c); + return 0; +#endif /* ACE_USES_WCHAR */ +} + +ACEXML_INLINE int +ACEXML_Parser::isCombiningchar (const ACEXML_Char c) const +{ +#if defined (ACE_USES_WCHAR) + return ACEXML_ParserInt::isCombiningchar_i (c); +#else + ACE_UNUSED_ARG (c); return 0; +#endif /* ACE_USES_WCHAR */ } + +ACEXML_INLINE int +ACEXML_Parser::isDigit (const ACEXML_Char c) const +{ +#if defined (ACE_USES_WCHAR) + return ACEXML_ParserInt::isDigit_i (c); +#else + return (this->isNormalDigit (c)); +#endif /* ACE_USES_WCHAR */ +} + +ACEXML_INLINE int +ACEXML_Parser::isExtender (const ACEXML_Char c) const +{ +#if defined (ACE_USES_WCHAR) + return ACEXML_ParserInt::isExtender_i (c); +#else + return (c == '\xB7'); +#endif /* ACE_USES_WCHAR */ } +ACEXML_INLINE int +ACEXML_Parser::isLetter (const ACEXML_Char c) const +{ + return (this->isBasechar (c) || this->isIdeographic (c)); +} ACEXML_INLINE int -ACEXML_Parser::is_whitespace_or_equal (ACEXML_Char c) +ACEXML_Parser::isNameChar (const ACEXML_Char c) const { - return (is_whitespace (c) || c == '=') ? 1 : 0; + return (this->isLetter (c) || this->isDigit (c) || c == '.' || c == '-' || + c == '_' || c == ':' || this->isCombiningchar (c) || + this->isExtender (c)); } ACEXML_INLINE int -ACEXML_Parser::is_nonname (ACEXML_Char c) +ACEXML_Parser::isPubidChar (const ACEXML_Char c) const { - // Handle this separately as doing so avoids code duplication and enables - // setting of line and column numbers in one place. - if (is_whitespace_or_equal (c)) - return 1; + return (c == '\x20' || c == '\x0D' || c == '\x0A' || + (c >= 'a' && c <= 'z') || (c >= 'A' && c <= 'Z') || + (c >= '0' && c <= '9') || c == '-' || c == '\'' || c == '(' || + c == ')' || c == '+' || c == ',' || c == '.' || c == '/' || + c == ':' || c == '=' || c == '?' || c == ';' || c == '!' || + c == '*' || c == '#' || c == '@' || c == '$' || c == '_' || + c == '%'); +} + +ACEXML_INLINE int +ACEXML_Parser::is_whitespace (const ACEXML_Char c) const +{ switch (c) { - case '/': - case '?': - case '>': - case '<': - case ')': - case '(': - case '+': - case '*': - case '\'': - case '"': - case ',': - case '|': + case '\x0A': case '\x20': + case '\x09': case '\x0D': return 1; default: return 0; @@ -107,20 +171,59 @@ ACEXML_Parser::is_nonname (ACEXML_Char c) } ACEXML_INLINE ACEXML_Char +ACEXML_Parser::skip_whitespace (void) +{ + ACEXML_Char ch = this->get(); + while (this->is_whitespace (ch)) + ch = this->get (); + return ch; +} + + +ACEXML_INLINE int +ACEXML_Parser::skip_whitespace_count (ACEXML_Char *peeky) +{ + int wscount = 0; + ACEXML_Char dummy; + ACEXML_Char &forward = (peeky == 0 ? dummy : *peeky); + + for (;this->is_whitespace ((forward = this->peek ())); ++wscount) + this->get (); + return wscount; +} + +ACEXML_INLINE int +ACEXML_Parser::skip_equal (void) +{ + if (this->skip_whitespace() != '=') + return -1; + while (this->is_whitespace (this->peek())) + this->get(); + return 0; +} + +ACEXML_INLINE ACEXML_Char ACEXML_Parser::get (void) { - // Using an extra level of indirection so we can - // manage document location in the future. + ACEXML_Char ch = 0; + const ACEXML_InputSource* ip = this->current_->getInputSource(); + ACEXML_CharStream* instream = ip->getCharStream(); - if (this->instream_ != 0) + if (instream->get (ch) != -1) { - ACEXML_Char ch; - if (this->instream_->get (ch) == -1) // EOF reached. - return 0; - this->locator_.incrColumnNumber(); - if (ch == 0x0A) { - this->locator_.incrLineNumber(); - this->locator_.setColumnNumber (0); + this->current_->getLocator()->incrColumnNumber(); + // Normalize white-space + if (ch == '\x0D') + { + if (instream->peek() == 0x0A) + instream->get (ch); + ch = '\x0A'; + } + if (ch == '\x0A') + { + // Reset column number and increment Line Number. + this->current_->getLocator()->incrLineNumber(); + this->current_->getLocator()->setColumnNumber (0); } return ch; } @@ -132,9 +235,24 @@ ACEXML_Parser::peek (void) { // Using an extra level of indirection so we can // manage document location in the future. + ACEXML_Char ch = 0; + const ACEXML_InputSource* ip = this->current_->getInputSource(); + ACEXML_CharStream* instream = ip->getCharStream(); + ch = instream->peek (); + return (ch == -1 ? 0 : ch); +} - if (this->instream_ != 0) - return this->instream_->peek (); +ACEXML_INLINE int +ACEXML_Parser::parse_token (const ACEXML_Char* keyword) +{ + if (keyword == 0) + return -1; + const ACEXML_Char* ptr = keyword; + ACEXML_Char ch; + for (; *ptr != 0 && ((ch = this->get()) == *ptr); ++ptr) + ; + if (*ptr == 0) return 0; - + else + return -1; } diff --git a/ACEXML/parser/parser/ParserContext.cpp b/ACEXML/parser/parser/ParserContext.cpp new file mode 100644 index 00000000000..fd0792677fb --- /dev/null +++ b/ACEXML/parser/parser/ParserContext.cpp @@ -0,0 +1,15 @@ +// $Id$ + +#include "ACEXML/parser/parser/ParserContext.h" + +#if !defined (__ACEXML_INLINE__) +# include "ACEXML/parser/parser/ParserContext.inl" +#endif /* __ACEXML_INLINE__ */ + +ACEXML_Parser_Context::~ACEXML_Parser_Context() +{ + delete this->instream_; + this->instream_ = 0; + delete this->locator_; + this->locator_ = 0; +} diff --git a/ACEXML/parser/parser/ParserContext.h b/ACEXML/parser/parser/ParserContext.h new file mode 100644 index 00000000000..bc02d68b360 --- /dev/null +++ b/ACEXML/parser/parser/ParserContext.h @@ -0,0 +1,79 @@ +// -*- C++ -*- + +//============================================================================= +/** + * @file ParserContext.h + * + * $Id$ + * + * @author Krishnakumar B <kitty@cs.wustl.edu> + */ +//============================================================================= + +#ifndef ACEXML_PARSER_CONTEXT_H +#define ACEXML_PARSER_CONTEXT_H + +#include "ace/pre.h" +#include "ACEXML/parser/parser/Parser_export.h" + +#if !defined (ACE_LACKS_PRAGMA_ONCE) +#pragma once +#endif /* ACE_LACKS_PRAGMA_ONCE */ + +#include "ACEXML/common/XML_Types.h" +#include "ACEXML/common/InputSource.h" +#include "ACEXML/common/Locator.h" +#include "ACEXML/common/LocatorImpl.h" +#include "ace/Functor.h" +#include "ace/Containers_T.h" +#include "ace/Swap.h" + +class ACEXML_PARSER_Export ACEXML_Parser_Context +{ +public: + /// Default constructor + ACEXML_Parser_Context(); + + /// Constructor which initializes the context + ACEXML_Parser_Context (ACEXML_InputSource* instream, + ACEXML_LocatorImpl* locator); + + /// Copy constructor + ACEXML_Parser_Context (const ACEXML_Parser_Context& src); + + /// Assignment operator + ACEXML_Parser_Context& operator= (const ACEXML_Parser_Context& src); + + /// Comparison operator + int operator!= (const ACEXML_Parser_Context& src); + + /// Destructor + virtual ~ACEXML_Parser_Context(); + + /// Reset the parser context. This does not free up the memory. Only sets + /// it to zero. Meant to be called after a context is pushed on to a + /// stack. + void reset (void); + + /// Get the underlying input source. + virtual ACEXML_InputSource* getInputSource(void); + + /// Get the underlying locator. + virtual ACEXML_LocatorImpl* getLocator(void); + +private: + + /// Current input char stream. + ACEXML_InputSource *instream_; + + /// Current Locator which provides line no., column no. systemId and publicId + ACEXML_LocatorImpl* locator_; +}; + +#if defined (__ACEXML_INLINE__) +# include "ACEXML/parser/parser/ParserContext.inl" +#endif /* __ACEXML_INLINE__ */ + +#include "ace/post.h" + +#endif /* ACEXML_PARSER_CONTEXT_H */ diff --git a/ACEXML/parser/parser/ParserContext.inl b/ACEXML/parser/parser/ParserContext.inl new file mode 100644 index 00000000000..7d896f65ee0 --- /dev/null +++ b/ACEXML/parser/parser/ParserContext.inl @@ -0,0 +1,62 @@ +// $Id$ + + +ACEXML_INLINE +ACEXML_Parser_Context::ACEXML_Parser_Context() + : instream_ (0), + locator_ (0) +{ + +} + +ACEXML_INLINE +ACEXML_Parser_Context::ACEXML_Parser_Context (ACEXML_InputSource* instream, + ACEXML_LocatorImpl* locator) + : instream_ (instream), + locator_ (locator) +{ + +} + +ACEXML_INLINE +ACEXML_Parser_Context::ACEXML_Parser_Context (const ACEXML_Parser_Context& src) + : instream_ (src.instream_), + locator_ (src.locator_) +{ + +} + +ACEXML_INLINE int +ACEXML_Parser_Context::operator!= (const ACEXML_Parser_Context& src) +{ + return (this->instream_ != src.instream_ && this->locator_ != src.locator_); +} + +ACEXML_INLINE ACEXML_Parser_Context& +ACEXML_Parser_Context::operator= (const ACEXML_Parser_Context& src) +{ + ACEXML_Parser_Context tmp (src); + ACE_Swap<ACEXML_InputSource*>::swap (this->instream_, tmp.instream_); + ACE_Swap<ACEXML_LocatorImpl*>::swap (this->locator_, tmp.locator_); + return *this; +} + + +ACEXML_INLINE ACEXML_InputSource* +ACEXML_Parser_Context::getInputSource (void) +{ + return this->instream_; +}; + +ACEXML_INLINE ACEXML_LocatorImpl* +ACEXML_Parser_Context::getLocator (void) +{ + return this->locator_; +} + +ACEXML_INLINE void +ACEXML_Parser_Context::reset (void) +{ + this->instream_ = 0; + this->locator_ = 0; +} diff --git a/ACEXML/parser/parser/ParserInternals.cpp b/ACEXML/parser/parser/ParserInternals.cpp new file mode 100644 index 00000000000..38db8291fa5 --- /dev/null +++ b/ACEXML/parser/parser/ParserInternals.cpp @@ -0,0 +1,394 @@ +// $Id$ + +#include "ACEXML/parser/parser/ParserInternals.h" + + +const ACEXML_Char* ACEXML_ParserInt::predef_ent_[] = { + ACE_TEXT ("amp"), + ACE_TEXT ("lt"), + ACE_TEXT ("gt"), + ACE_TEXT ("apos"), + ACE_TEXT ("quot") +}; + +const ACEXML_Char* ACEXML_ParserInt::predef_val_[] = { + ACE_TEXT ("&"), + ACE_TEXT ("<"), + ACE_TEXT (">"), + ACE_TEXT ("'"), + ACE_TEXT ("\"") +}; + +// Optimize away the most common cases. Any compiler worth it's salt should +// give generate a single memory access. + +const ACEXML_Char ACEXML_ParserInt::base_char_table_[] = { + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0000 - 0x000F */ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0010 - 0x001F */ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0020 - 0x002F */ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0030 - 0x003F */ + 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, /* 0x0040 - 0x004F */ + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, /* 0x0050 - 0x005F */ + 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, /* 0x0060 - 0x006F */ + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, /* 0x0070 - 0x007F */ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0080 - 0x008F */ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0090 - 0x009F */ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x00A0 - 0x00AF */ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x00B0 - 0x00BF */ + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, /* 0x00C0 - 0x00CF */ + 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, /* 0x00D0 - 0x00DF */ + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, /* 0x00E0 - 0x00EF */ + 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, /* 0x00F0 - 0x00FF */ +}; + +#if defined (ACE_USES_WCHAR) + +int +ACEXML_ParserInt::isBasechar_i (const ACEXML_Char c) +{ + if (c < 0x0100) + return ACEXML_ParserInt::base_char_table_[c]; + else if (c < 0x0905) + return ((c >= 0x0100 && c <= 0x0131) || + (c >= 0x0134 && c <= 0x013E) || + (c >= 0x0141 && c <= 0x0148) || + (c >= 0x014A && c <= 0x017E) || + (c >= 0x0180 && c <= 0x01C3) || + (c >= 0x01CD && c <= 0x01F0) || + (c >= 0x01F4 && c <= 0x01F5) || + (c >= 0x01FA && c <= 0x0217) || + (c >= 0x0250 && c <= 0x02A8) || + (c >= 0x02BB && c <= 0x02C1) || + (c == 0x0386) || + (c >= 0x0388 && c <= 0x038A) || + (c == 0x038C) || + (c >= 0x038E && c <= 0x03A1) || + (c >= 0x03A3 && c <= 0x03CE) || + (c >= 0x03D0 && c <= 0x03D6) || + (c == 0x03DA) || + (c == 0x03DC) || + (c == 0x03DE) || + (c == 0x03E0) || + (c >= 0x03E2 && c <= 0x03F3) || + (c >= 0x0401 && c <= 0x040C) || + (c >= 0x040E && c <= 0x044F) || + (c >= 0x0451 && c <= 0x045C) || + (c >= 0x045E && c <= 0x0481) || + (c >= 0x0490 && c <= 0x04C4) || + (c >= 0x04C7 && c <= 0x04C8) || + (c >= 0x04CB && c <= 0x04CC) || + (c >= 0x04D0 && c <= 0x04EB) || + (c >= 0x04EE && c <= 0x04F5) || + (c >= 0x04F8 && c <= 0x04F9) || + (c >= 0x0531 && c <= 0x0556) || + (c == 0x0559) || + (c >= 0x0561 && c <= 0x0586) || + (c >= 0x05D0 && c <= 0x05EA) || + (c >= 0x05F0 && c <= 0x05F2) || + (c >= 0x0621 && c <= 0x063A) || + (c >= 0x0641 && c <= 0x064A) || + (c >= 0x0671 && c <= 0x06B7) || + (c >= 0x06BA && c <= 0x06BE) || + (c >= 0x06C0 && c <= 0x06CE) || + (c >= 0x06D0 && c <= 0x06D3) || + (c == 0x06D5) || + (c >= 0x06E5 && c <= 0x06E6)); + else if (c < 0x10A0) + return ((c >= 0x0905 && c <= 0x0939) || + (c == 0x093D) || + (c >= 0x0958 && c <= 0x0961) || + (c >= 0x0985 && c <= 0x098C) || + (c >= 0x098F && c <= 0x0990) || + (c >= 0x0993 && c <= 0x09A8) || + (c >= 0x09AA && c <= 0x09B0) || + (c == 0x09B2) || + (c >= 0x09B6 && c <= 0x09B9) || + (c >= 0x09DC && c <= 0x09DD) || + (c >= 0x09DF && c <= 0x09E1) || + (c >= 0x09F0 && c <= 0x09F1) || + (c >= 0x0A05 && c <= 0x0A0A) || + (c >= 0x0A0F && c <= 0x0A10) || + (c >= 0x0A13 && c <= 0x0A28) || + (c >= 0x0A2A && c <= 0x0A30) || + (c >= 0x0A32 && c <= 0x0A33) || + (c >= 0x0A35 && c <= 0x0A36) || + (c >= 0x0A38 && c <= 0x0A39) || + (c >= 0x0A59 && c <= 0x0A5C) || + (c == 0x0A5E) || + (c >= 0x0A72 && c <= 0x0A74) || + (c >= 0x0A85 && c <= 0x0A8B) || + (c == 0x0A8D) || + (c >= 0x0A8F && c <= 0x0A91) || + (c >= 0x0A93 && c <= 0x0AA8) || + (c >= 0x0AAA && c <= 0x0AB0) || + (c >= 0x0AB2 && c <= 0x0AB3) || + (c >= 0x0AB5 && c <= 0x0AB9) || + (c == 0x0ABD || c == 0x0AE0) || + (c >= 0x0B05 && c <= 0x0B0C) || + (c >= 0x0B0F && c <= 0x0B10) || + (c >= 0x0B13 && c <= 0x0B28) || + (c >= 0x0B2A && c <= 0x0B30) || + (c >= 0x0B32 && c <= 0x0B33) || + (c >= 0x0B36 && c <= 0x0B39) || + (c == 0x0B3D) || + (c >= 0x0B5C && c <= 0x0B5D) || + (c >= 0x0B5F && c <= 0x0B61) || + (c >= 0x0B85 && c <= 0x0B8A) || + (c >= 0x0B8E && c <= 0x0B90) || + (c >= 0x0B92 && c <= 0x0B95) || + (c >= 0x0B99 && c <= 0x0B9A) || + (c == 0x0B9C) || + (c >= 0x0B9E && c <= 0x0B9F) || + (c >= 0x0BA3 && c <= 0x0BA4) || + (c >= 0x0BA8 && c <= 0x0BAA) || + (c >= 0x0BAE && c <= 0x0BB5) || + (c >= 0x0BB7 && c <= 0x0BB9) || + (c >= 0x0C05 && c <= 0x0C0C) || + (c >= 0x0C0E && c <= 0x0C10) || + (c >= 0x0C12 && c <= 0x0C28) || + (c >= 0x0C2A && c <= 0x0C33) || + (c >= 0x0C35 && c <= 0x0C39) || + (c >= 0x0C60 && c <= 0x0C61) || + (c >= 0x0C85 && c <= 0x0C8C) || + (c >= 0x0C8E && c <= 0x0C90) || + (c >= 0x0C92 && c <= 0x0CA8) || + (c >= 0x0CAA && c <= 0x0CB3) || + (c >= 0x0CB5 && c <= 0x0CB9) || + (c == 0x0CDE) || + (c >= 0x0CE0 && c <= 0x0CE1) || + (c >= 0x0D05 && c <= 0x0D0C) || + (c >= 0x0D0E && c <= 0x0D10) || + (c >= 0x0D12 && c <= 0x0D28) || + (c >= 0x0D2A && c <= 0x0D39) || + (c >= 0x0D60 && c <= 0x0D61) || + (c >= 0x0E01 && c <= 0x0E2E) || + (c == 0x0E30) || + (c >= 0x0E32 && c <= 0x0E33) || + (c >= 0x0E40 && c <= 0x0E45) || + (c >= 0x0E81 && c <= 0x0E82) || + (c == 0x0E84) || + (c >= 0x0E87 && c <= 0x0E88) || + (c == 0x0E8A || c == 0x0E8D) || + (c >= 0x0E94 && c <= 0x0E97) || + (c >= 0x0E99 && c <= 0x0E9F) || + (c >= 0x0EA1 && c <= 0x0EA3) || + (c == 0x0EA5 || c == 0x0EA7) || + (c >= 0x0EAA && c <= 0x0EAB) || + (c >= 0x0EAD && c <= 0x0EAE) || + (c == 0x0EB0) || + (c >= 0x0EB2 && c <= 0x0EB3) || + (c == 0x0EBD) || + (c >= 0x0EC0 && c <= 0x0EC4) || + (c >= 0x0F40 && c <= 0x0F47) || + (c >= 0x0F49 && c <= 0x0F69)); + else + return ((c >= 0x10A0 && c <= 0x10C5) || + (c >= 0x10D0 && c <= 0x10F6) || + (c == 0x1100) || + (c >= 0x1102 && c <= 0x1103) || + (c >= 0x1105 && c <= 0x1107) || + (c == 0x1109) || + (c >= 0x110B && c <= 0x110C) || + (c >= 0x110E && c <= 0x1112) || + (c == 0x113C || c == 0x113E || c == 0x1140) || + (c == 0x114C || c == 0x114E || c == 0x1150) || + (c >= 0x1154 && c <= 0x1155) || + (c == 0x1159) || + (c >= 0x115F && c <= 0x1161) || + (c == 0x1163) || + (c == 0x1165) || + (c == 0x1167) || + (c == 0x1169) || + (c >= 0x116D && c <= 0x116E) || + (c >= 0x1172 && c <= 0x1173) || + (c == 0x1175) || + (c == 0x119E) || + (c == 0x11A8) || + (c == 0x11AB) || + (c >= 0x11AE && c <= 0x11AF) || + (c >= 0x11B7 && c <= 0x11B8) || + (c == 0x11BA) || + (c >= 0x11BC && c <= 0x11C2) || + (c == 0x11EB) || + (c == 0x11F0) || + (c == 0x11F9) || + (c >= 0x1E00 && c <= 0x1E9B) || + (c >= 0x1EA0 && c <= 0x1EF9) || + (c >= 0x1F00 && c <= 0x1F15) || + (c >= 0x1F18 && c <= 0x1F1D) || + (c >= 0x1F20 && c <= 0x1F45) || + (c >= 0x1F48 && c <= 0x1F4D) || + (c >= 0x1F50 && c <= 0x1F57) || + (c == 0x1F59) || + (c == 0x1F5B) || + (c == 0x1F5D) || + (c >= 0x1F5F && c <= 0x1F7D) || + (c >= 0x1F80 && c <= 0x1FB4) || + (c >= 0x1FB6 && c <= 0x1FBC) || + (c == 0x1FBE) || + (c >= 0x1FC2 && c <= 0x1FC4) || + (c >= 0x1FC6 && c <= 0x1FCC) || + (c >= 0x1FD0 && c <= 0x1FD3) || + (c >= 0x1FD6 && c <= 0x1FDB) || + (c >= 0x1FE0 && c <= 0x1FEC) || + (c >= 0x1FF2 && c <= 0x1FF4) || + (c >= 0x1FF6 && c <= 0x1FFC) || + (c == 0x2126) || + (c >= 0x212A && c <= 0x212B) || + (c == 0x212E) || + (c >= 0x2180 && c <= 0x2182) || + (c >= 0x3041 && c <= 0x3094) || + (c >= 0x30A1 && c <= 0x30FA) || + (c >= 0x3105 && c <= 0x312C) || + (c >= 0xAC00 && c <= 0xD7A3)); +}; + +int +ACEXML_ParserInt::isIdeographic_i (const ACEXML_Char c) +{ + return ((c >= 0x4E00 && c <= 0x9FA5) || + (c == 3007) || + (c >= 0x3021 && c <= 0x3029)); +} + +int +ACEXML_ParserInt::isCombiningchar_i (const ACEXML_Char c) +{ + if (c < 0x0901) + return ((c >= 0x0300 && c <= 0x0345) || + (c >= 0x0360 && c <= 0x0361) || + (c >= 0x0483 && c <= 0x0486) || + (c >= 0x0591 && c <= 0x05A1) || + (c >= 0x05A3 && c <= 0x05B9) || + (c >= 0x05BB && c <= 0x05BD) || + (c == 0x05BF) || + (c >= 0x05C1 && c <= 0x05C2) || + (c == 0x05C4) || + (c >= 0x064B && c <= 0x0652) || + (c == 0x0670) || + (c >= 0x06D6 && c <= 0x06DC) || + (c >= 0x06DD && c <= 0x06DF) || + (c >= 0x06E0 && c <= 0x06E4) || + (c >= 0x06E7 && c <= 0x06E8) || + (c >= 0x06EA && c <= 0x06ED)); + else + return ((c >= 0x0901 && c <= 0x0903) || + (c == 0x093C) || + (c >= 0x093E && c <= 0x094C) || + (c == 0x094D) || + (c >= 0x0951 && c <= 0x0954) || + (c >= 0x0962 && c <= 0x0963) || + (c >= 0x0981 && c <= 0x0983) || + (c == 0x09BC) || + (c == 0x09BE) || + (c == 0x09BF) || + (c >= 0x09C0 && c <= 0x09C4) || + (c >= 0x09C7 && c <= 0x09C8) || + (c >= 0x09CB && c <= 0x09CD) || + (c == 0x09D7) || + (c >= 0x09E2 && c <= 0x09E3) || + (c == 0x0A02) || + (c == 0x0A3C) || + (c == 0x0A3E) || + (c == 0x0A3F) || + (c >= 0x0A40 && c <= 0x0A42) || + (c >= 0x0A47 && c <= 0x0A48) || + (c >= 0x0A4B && c <= 0x0A4D) || + (c >= 0x0A70 && c <= 0x0A71) || + (c >= 0x0A81 && c <= 0x0A83) || + (c == 0x0ABC) || + (c >= 0x0ABE && c <= 0x0AC5) || + (c >= 0x0AC7 && c <= 0x0AC9) || + (c >= 0x0ACB && c <= 0x0ACD) || + (c >= 0x0B01 && c <= 0x0B03) || + (c == 0x0B3C) || + (c >= 0x0B3E && c <= 0x0B43) || + (c >= 0x0B47 && c <= 0x0B48) || + (c >= 0x0B4B && c <= 0x0B4D) || + (c >= 0x0B56 && c <= 0x0B57) || + (c >= 0x0B82 && c <= 0x0B83) || + (c >= 0x0BBE && c <= 0x0BC2) || + (c >= 0x0BC6 && c <= 0x0BC8) || + (c >= 0x0BCA && c <= 0x0BCD) || + (c == 0x0BD7) || + (c >= 0x0C01 && c <= 0x0C03) || + (c >= 0x0C3E && c <= 0x0C44) || + (c >= 0x0C46 && c <= 0x0C48) || + (c >= 0x0C4A && c <= 0x0C4D) || + (c >= 0x0C55 && c <= 0x0C56) || + (c >= 0x0C82 && c <= 0x0C83) || + (c >= 0x0CBE && c <= 0x0CC4) || + (c >= 0x0CC6 && c <= 0x0CC8) || + (c >= 0x0CCA && c <= 0x0CCD) || + (c >= 0x0CD5 && c <= 0x0CD6) || + (c >= 0x0D02 && c <= 0x0D03) || + (c >= 0x0D3E && c <= 0x0D43) || + (c >= 0x0D46 && c <= 0x0D48) || + (c >= 0x0D4A && c <= 0x0D4D) || + (c == 0x0D57) || + (c == 0x0E31) || + (c >= 0x0E34 && c <= 0x0E3A) || + (c >= 0x0E47 && c <= 0x0E4E) || + (c == 0x0EB1) || + (c >= 0x0EB4 && c <= 0x0EB9) || + (c >= 0x0EBB && c <= 0x0EBC) || + (c >= 0x0EC8 && c <= 0x0ECD) || + (c >= 0x0F18 && c <= 0x0F19) || + (c == 0x0F35) || + (c == 0x0F37) || + (c == 0x0F39) || + (c == 0x0F3E) || + (c == 0x0F3F) || + (c >= 0x0F71 && c <= 0x0F84) || + (c >= 0x0F86 && c <= 0x0F8B) || + (c >= 0x0F90 && c <= 0x0F95) || + (c == 0x0F97) || + (c >= 0x0F99 && c <= 0x0FAD) || + (c >= 0x0FB1 && c <= 0x0FB7) || + (c == 0x0FB9) || + (c >= 0x20D0 && c <= 0x20DC) || + (c == 0x20E1) || + (c >= 0x302A && c <= 0x302F) || + (c == 0x3099) || + (c == 0x309A)); +} + +int +ACEXML_ParserInt::isDigit_i (const ACEXML_Char c) +{ + if (c < 0x0040) + return (c >= 0x0030 && c <= 0x0039); + else + return ((c >= 0x0660 && c <= 0x0669) || + (c >= 0x06F0 && c <= 0x06F9) || + (c >= 0x0966 && c <= 0x096F) || + (c >= 0x09E6 && c <= 0x09EF) || + (c >= 0x0A66 && c <= 0x0A6F) || + (c >= 0x0AE6 && c <= 0x0AEF) || + (c >= 0x0B66 && c <= 0x0B6F) || + (c >= 0x0BE7 && c <= 0x0BEF) || + (c >= 0x0C66 && c <= 0x0C6F) || + (c >= 0x0CE6 && c <= 0x0CEF) || + (c >= 0x0D66 && c <= 0x0D6F) || + (c >= 0x0E50 && c <= 0x0E59) || + (c >= 0x0ED0 && c <= 0x0ED9) || + (c >= 0x0F20 && c <= 0x0F29)); +} + +int +ACEXML_ParserInt::isExtender_i (const ACEXML_Char c) +{ + // The compiler should generate a jump table and index into it directly. + switch (c) + { + case 0x00B7: case 0x02D0: case 0x02D1: case 0x0387: case 0x0640: + case 0x0E46: case 0x0EC6: case 0x3005: case 0x3031: case 0x3032: + case 0x3033: case 0x3034: case 0x3035: case 0x309D: case 0x309E: + case 0x30FC: case 0x30FD: case 0x30FE: + return 1; + default: + return 0; + } +} + +#endif /* ACE_USES_WCHAR */ diff --git a/ACEXML/parser/parser/ParserInternals.h b/ACEXML/parser/parser/ParserInternals.h new file mode 100644 index 00000000000..9ccb3dbf914 --- /dev/null +++ b/ACEXML/parser/parser/ParserInternals.h @@ -0,0 +1,104 @@ +// -*- C++ -*- + +//============================================================================= +/** + * @file ParserInternals.h + * + * $Id$ + * + * @author Krishnakumar B <kitty@cs.wustl.edu> + */ +//============================================================================= + +#ifndef _ACEXML_PARSER_INTERNALS_H_ +#define _ACEXML_PARSER_INTERNALS_H_ + +#include "ace/pre.h" +#include "ACEXML/parser/parser/Parser_export.h" + +#if !defined (ACE_LACKS_PRAGMA_ONCE) +#pragma once +#endif /* ACE_LACKS_PRAGMA_ONCE */ + +#include "ACEXML/common/XML_Types.h" + +/** + * @class ACEXML_ParserInt ParserInternals.h "ACEXML/parser/parser/ParserInternals.h" + * + * @brief A class to hide some of the internal implementation details of + * the parser. + * + */ +class ACEXML_PARSER_Export ACEXML_ParserInt +{ + +public: +#if defined (ACE_USES_WCHAR) + + /** + * Check if a character @a c is a BaseChar. This method checks for the + * complete set of characters allowed when WCHAR support is enabled. + * + * @retval 1 if @a c is a valid XML Character, 0 otherwise. + */ + static int isBasechar_i (const ACEXML_Char c); + + /** + * Check if a character @a c is a Ideographic. This method checks for the + * complete set of characters allowed when WCHAR support is enabled. + * + * @retval 1 if @a c is a valid XML Character, 0 otherwise. + */ + static int isIdeographic_i (const ACEXML_Char c); + + /** + * Check if a character @a c is a CombiningChar. This method checks for the + * complete set of characters allowed when WCHAR support is enabled. + * + * @retval 1 if @a c is a valid XML Character, 0 otherwise. + */ + static int isCombiningchar_i (const ACEXML_Char c); + + /** + * Check if a character @a c is a Digit. This method checks for the + * complete set of characters allowed when WCHAR support is enabled. + * + * @retval 1 if @a c is a valid XML Character, 0 otherwise. + */ + static int isDigit_i (const ACEXML_Char c); + + /** + * Check if a character @a c is an Extender. This method checks for the + * complete set of characters allowed when WCHAR support is enabled. + * + * @retval 1 if @a c is a valid XML Character, 0 otherwise. + */ + static int isExtender_i (const ACEXML_Char c); + +#endif /* ACE_USES_WCHAR */ + + static const ACEXML_Char base_char_table_[256]; + + static const ACEXML_Char* msg_[]; + + static const ACEXML_Char* predef_ent_[]; + + static const ACEXML_Char* predef_val_[]; + + // Enum describing the position in a document when a reference occurs. + enum ReferenceState { + IN_CONTENT, + IN_ATT_VALUE, + AS_ATT_VALUE, + IN_ENTITY_VALUE, + IN_INT_DTD, + IN_EXT_DTD, + IN_NOTATION, + INVALID = -1 + }; + +}; + +#include "ace/post.h" + +#endif /* _ACEXML_PARSER_INTERNALS_H_ */ diff --git a/ACEXML/tests/ContentHandler_Test.cpp b/ACEXML/tests/ContentHandler_Test.cpp index b91557cb896..d81ed1bc64e 100644 --- a/ACEXML/tests/ContentHandler_Test.cpp +++ b/ACEXML/tests/ContentHandler_Test.cpp @@ -71,8 +71,13 @@ ACE_TMAIN (int, ACE_TCHAR *[]) { int status = 0; Basic_Content_Tester tester; - ACEXML_StrCharStream *test_stream = - new ACEXML_StrCharStream (tester.get_test_string ()); + ACEXML_StrCharStream *test_stream = 0; + ACE_NEW_RETURN (test_stream, ACEXML_StrCharStream, -1); + if (test_stream->open (tester.get_test_string (), ACE_TEXT ("test_stream")) < 0) + { + ACE_ERROR ((LM_ERROR, ACE_TEXT ("Unable to create input stream\n"))); + return -1; + } ACEXML_InputSource input (test_stream); ACEXML_Parser parser; parser.setContentHandler (&tester); diff --git a/ACEXML/tests/ContentHandler_Test.dsp b/ACEXML/tests/ContentHandler_Test.dsp index 84ab3108878..2628e355df4 100644 --- a/ACEXML/tests/ContentHandler_Test.dsp +++ b/ACEXML/tests/ContentHandler_Test.dsp @@ -1,25 +1,26 @@ -# Microsoft Developer Studio Project File - Name="ContentHandler_Test" - Package Owner=<4>
+# Microsoft Developer Studio Project File - Name="ContentHandler_Test EXE" - Package Owner=<4>
# Microsoft Developer Studio Generated Build File, Format Version 6.00
# ** DO NOT EDIT **
# TARGTYPE "Win32 (x86) Console Application" 0x0103
-CFG=ContentHandler_Test - Win32 Debug
+CFG=ContentHandler_Test EXE - Win32 Debug
!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
+!MESSAGE run the tool that generated this project file and specify the
+!MESSAGE nmake output type. You can then use the following command:
+!MESSAGE
!MESSAGE NMAKE /f "ContentHandler_Test.mak".
-!MESSAGE
+!MESSAGE
!MESSAGE You can specify a configuration when running NMAKE
!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "ContentHandler_Test.mak" CFG="ContentHandler_Test - Win32 Debug"
-!MESSAGE
+!MESSAGE
+!MESSAGE NMAKE /f "ContentHandler_Test.mak" CFG="ContentHandler_Test EXE - Win32 Debug"
+!MESSAGE
!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "ContentHandler_Test - Win32 Release" (based on "Win32 (x86) Console Application")
-!MESSAGE "ContentHandler_Test - Win32 Debug" (based on "Win32 (x86) Console Application")
-!MESSAGE
+!MESSAGE
+!MESSAGE "ContentHandler_Test EXE - Win32 Release" (based on "Win32 (x86) Console Application")
+!MESSAGE "ContentHandler_Test EXE - Win32 Debug" (based on "Win32 (x86) Console Application")
+!MESSAGE
# Begin Project
# PROP AllowPerConfigDependencies 0
@@ -28,77 +29,49 @@ CFG=ContentHandler_Test - Win32 Debug CPP=cl.exe
RSC=rc.exe
-!IF "$(CFG)" == "ContentHandler_Test - Win32 Release"
+!IF "$(CFG)" == "ContentHandler_Test EXE - Win32 Release"
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release"
-# PROP BASE Intermediate_Dir "Release"
-# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 0
# PROP Output_Dir "Release"
-# PROP Intermediate_Dir "Release"
-# PROP Ignore_Export_Lib 0
+# PROP Intermediate_Dir "Release\ContentHandler_Test"
# PROP Target_Dir ""
-# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "../.." /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
+# ADD CPP /nologo /W3 /GX /O2 /MD /GR /I "..\.." /D NDEBUG=1 /D WIN32=1 /D _CONSOLE=1 /FD /c
# SUBTRACT CPP /YX
-# ADD BASE RSC /l 0x409 /d "NDEBUG"
-# ADD RSC /l 0x409 /d "NDEBUG"
+# ADD RSC /l 0x409 /d NDEBUG=1 /i "..\.."
BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
+# ADD BSC32 /nologo
LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386
-# ADD LINK32 ace.lib ACEXML_Parser.lib ACEXML.lib /nologo /subsystem:console /machine:I386 /libpath:"..\..\ace" /libpath:"..\Common" /libpath:"..\parser\parser"
+# ADD LINK32 advapi32.lib user32.lib /INCREMENTAL:NO ACEXML_Parser.lib ACEXML.lib ACE.lib /libpath:"..\..\ACEXML\common" /libpath:"..\..\ACEXML\parser\parser" /libpath:"..\..\ace" /nologo /version:5.3.1 /subsystem:console /pdb:"Release\ContentHandler_Test.pdb" /machine:I386 /out:"Release\ContentHandler_Test.exe"
-!ELSEIF "$(CFG)" == "ContentHandler_Test - Win32 Debug"
+!ELSEIF "$(CFG)" == "ContentHandler_Test EXE - Win32 Debug"
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug"
-# PROP BASE Intermediate_Dir "Debug"
-# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 1
-# PROP Output_Dir ""
-# PROP Intermediate_Dir "Debug"
-# PROP Ignore_Export_Lib 0
+# PROP Output_Dir "."
+# PROP Intermediate_Dir "Debug\ContentHandler_Test"
# PROP Target_Dir ""
-# ADD BASE CPP /nologo /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /Zi /Od /I "../.." /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
+# ADD CPP /nologo /W3 /Gm /GX /Zi /Od /MDd /GR /Gy /I "..\.." /D _DEBUG=1 /D WIN32=1 /D _CONSOLE=1 /FD /c
# SUBTRACT CPP /YX
-# ADD BASE RSC /l 0x409 /d "_DEBUG"
-# ADD RSC /l 0x409 /d "_DEBUG"
+# ADD RSC /l 0x409 /d _DEBUG=1 /i "..\.."
BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
+# ADD BSC32 /nologo
LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 aced.lib ACEXML_Parserd.lib ACEXMLd.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept /libpath:"..\..\ace" /libpath:"..\Common" /libpath:"..\parser\parser"
+# ADD LINK32 advapi32.lib user32.lib /INCREMENTAL:NO ACEXML_Parserd.lib ACEXMLd.lib ACEd.lib /libpath:"..\..\ACEXML\common" /libpath:"..\..\ACEXML\parser\parser" /libpath:"..\..\ace" /nologo /version:5.3.1 /subsystem:console /pdb:".\ContentHandler_Test.pdb" /debug /machine:I386 /out:".\ContentHandler_Test.exe"
-!ENDIF
+!ENDIF
# Begin Target
-# Name "ContentHandler_Test - Win32 Release"
-# Name "ContentHandler_Test - Win32 Debug"
+# Name "ContentHandler_Test EXE - Win32 Release"
+# Name "ContentHandler_Test EXE - Win32 Debug"
# Begin Group "Source Files"
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
+# PROP Default_Filter "cpp;cxx;c"
# Begin Source File
SOURCE=.\ContentHandler_Test.cpp
# End Source File
# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# End Group
-# Begin Group "Resource Files"
-
-# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
-# End Group
# End Target
# End Project
diff --git a/ACEXML/tests/HttpCharStream_Test.cpp b/ACEXML/tests/HttpCharStream_Test.cpp index 982fbcd4e34..b30dc7fa55a 100644 --- a/ACEXML/tests/HttpCharStream_Test.cpp +++ b/ACEXML/tests/HttpCharStream_Test.cpp @@ -4,32 +4,35 @@ int ACE_TMAIN (int, ACE_TCHAR *[]) { - const ACEXML_Char* test = ACE_TEXT("http://www.cs.wustl.edu/~nanbor/"); + const ACEXML_Char* test = ACE_TEXT("http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"); - const ACEXML_Char* simple = ACE_TEXT("http://www.cs.wustl.edu/~kitty/"); + const ACEXML_Char* simple = ACE_TEXT("http://www.w3.org/TR/xhtml1/DTD/xhtml-lat1.ent"); - ACEXML_HttpCharStream stream; + ACEXML_HttpCharStream first; + ACEXML_HttpCharStream second; ACEXML_Char ch; - if (stream.open (test) != -1) + if (first.open (test) != -1) { - while (stream.get (ch) != -1) + while (first.get (ch) != -1) ACE_OS::printf ("%c", ch); - stream.close(); } else { + first.close(); ACE_ERROR ((LM_ERROR, "Error in opening stream : %m\n")); } - - if (stream.open (simple) != -1) + if (second.open (simple) != -1) { - while (stream.get (ch) != -1) + while (second.get (ch) != -1) ACE_OS::printf ("%c", ch); } else { + second.close(); ACE_ERROR ((LM_ERROR, "Error in opening stream : %m\n")); } + first.close(); + second.close(); return 0; } diff --git a/ACEXML/tests/HttpCharStream_Test.dsp b/ACEXML/tests/HttpCharStream_Test.dsp index b2142eab85d..26b370c55a2 100644 --- a/ACEXML/tests/HttpCharStream_Test.dsp +++ b/ACEXML/tests/HttpCharStream_Test.dsp @@ -1,25 +1,26 @@ -# Microsoft Developer Studio Project File - Name="HttpCharStream_Test" - Package Owner=<4>
+# Microsoft Developer Studio Project File - Name="HttpCharStream_Test EXE" - Package Owner=<4>
# Microsoft Developer Studio Generated Build File, Format Version 6.00
# ** DO NOT EDIT **
# TARGTYPE "Win32 (x86) Console Application" 0x0103
-CFG=HttpCharStream_Test - Win32 Debug
+CFG=HttpCharStream_Test EXE - Win32 Debug
!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
+!MESSAGE run the tool that generated this project file and specify the
+!MESSAGE nmake output type. You can then use the following command:
+!MESSAGE
!MESSAGE NMAKE /f "HttpCharStream_Test.mak".
-!MESSAGE
+!MESSAGE
!MESSAGE You can specify a configuration when running NMAKE
!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "HttpCharStream_Test.mak" CFG="HttpCharStream_Test - Win32 Debug"
-!MESSAGE
+!MESSAGE
+!MESSAGE NMAKE /f "HttpCharStream_Test.mak" CFG="HttpCharStream_Test EXE - Win32 Debug"
+!MESSAGE
!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "HttpCharStream_Test - Win32 Release" (based on "Win32 (x86) Console Application")
-!MESSAGE "HttpCharStream_Test - Win32 Debug" (based on "Win32 (x86) Console Application")
-!MESSAGE
+!MESSAGE
+!MESSAGE "HttpCharStream_Test EXE - Win32 Release" (based on "Win32 (x86) Console Application")
+!MESSAGE "HttpCharStream_Test EXE - Win32 Debug" (based on "Win32 (x86) Console Application")
+!MESSAGE
# Begin Project
# PROP AllowPerConfigDependencies 0
@@ -28,77 +29,49 @@ CFG=HttpCharStream_Test - Win32 Debug CPP=cl.exe
RSC=rc.exe
-!IF "$(CFG)" == "HttpCharStream_Test - Win32 Release"
+!IF "$(CFG)" == "HttpCharStream_Test EXE - Win32 Release"
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release"
-# PROP BASE Intermediate_Dir "Release"
-# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 0
# PROP Output_Dir "Release"
-# PROP Intermediate_Dir "Release"
-# PROP Ignore_Export_Lib 0
+# PROP Intermediate_Dir "Release\HttpCharStream_Test"
# PROP Target_Dir ""
-# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "../.." /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
+# ADD CPP /nologo /W3 /GX /O2 /MD /GR /I "..\.." /D NDEBUG=1 /D WIN32=1 /D _CONSOLE=1 /FD /c
# SUBTRACT CPP /YX
-# ADD BASE RSC /l 0x409 /d "NDEBUG"
-# ADD RSC /l 0x409 /d "NDEBUG"
+# ADD RSC /l 0x409 /d NDEBUG=1 /i "..\.."
BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
+# ADD BSC32 /nologo
LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386
-# ADD LINK32 ace.lib ACEXML.lib /nologo /subsystem:console /machine:I386 /libpath:"..\..\ace" /libpath:"..\Common"
+# ADD LINK32 advapi32.lib user32.lib /INCREMENTAL:NO ACEXML_Parser.lib ACEXML.lib ACE.lib /libpath:"..\..\ACEXML\common" /libpath:"..\..\ACEXML\parser\parser" /libpath:"..\..\ace" /nologo /version:5.3.1 /subsystem:console /pdb:"Release\HttpCharStream_Test.pdb" /machine:I386 /out:"Release\HttpCharStream_Test.exe"
-!ELSEIF "$(CFG)" == "HttpCharStream_Test - Win32 Debug"
+!ELSEIF "$(CFG)" == "HttpCharStream_Test EXE - Win32 Debug"
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug"
-# PROP BASE Intermediate_Dir "Debug"
-# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 1
-# PROP Output_Dir ""
-# PROP Intermediate_Dir "Debug"
-# PROP Ignore_Export_Lib 0
+# PROP Output_Dir "."
+# PROP Intermediate_Dir "Debug\HttpCharStream_Test"
# PROP Target_Dir ""
-# ADD BASE CPP /nologo /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /Zi /Od /I "../.." /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
+# ADD CPP /nologo /W3 /Gm /GX /Zi /Od /MDd /GR /Gy /I "..\.." /D _DEBUG=1 /D WIN32=1 /D _CONSOLE=1 /FD /c
# SUBTRACT CPP /YX
-# ADD BASE RSC /l 0x409 /d "_DEBUG"
-# ADD RSC /l 0x409 /d "_DEBUG"
+# ADD RSC /l 0x409 /d _DEBUG=1 /i "..\.."
BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
+# ADD BSC32 /nologo
LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 aced.lib ACEXMLd.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept /libpath:"..\..\ace" /libpath:"..\Common"
+# ADD LINK32 advapi32.lib user32.lib /INCREMENTAL:NO ACEXML_Parserd.lib ACEXMLd.lib ACEd.lib /libpath:"..\..\ACEXML\common" /libpath:"..\..\ACEXML\parser\parser" /libpath:"..\..\ace" /nologo /version:5.3.1 /subsystem:console /pdb:".\HttpCharStream_Test.pdb" /debug /machine:I386 /out:".\HttpCharStream_Test.exe"
-!ENDIF
+!ENDIF
# Begin Target
-# Name "HttpCharStream_Test - Win32 Release"
-# Name "HttpCharStream_Test - Win32 Debug"
+# Name "HttpCharStream_Test EXE - Win32 Release"
+# Name "HttpCharStream_Test EXE - Win32 Debug"
# Begin Group "Source Files"
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
+# PROP Default_Filter "cpp;cxx;c"
# Begin Source File
SOURCE=.\HttpCharStream_Test.cpp
# End Source File
# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# End Group
-# Begin Group "Resource Files"
-
-# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
-# End Group
# End Target
# End Project
diff --git a/ACEXML/tests/Makefile b/ACEXML/tests/Makefile index 8ecb4688792..ce3a0589cc8 100644 --- a/ACEXML/tests/Makefile +++ b/ACEXML/tests/Makefile @@ -1,650 +1,24 @@ +# $Id$ #---------------------------------------------------------------------------- -# $Id$ -# -# Makefile for repeating token client application +# GNU ACE Workspace #---------------------------------------------------------------------------- -#---------------------------------------------------------------------------- -# Local macros -#---------------------------------------------------------------------------- - -LDLIBS = -lACEXML_Parser -lACEXML -BIN = Transcoder_Test \ - NamespaceSupport_Test \ - HttpCharStream_Test \ - ContentHandler_Test - -LSRC = $(addsuffix .cpp,$(BIN)) -LOBJ = $(LSRC:%.cpp=$(VDIR)%.o) -#SHOBJ = $(addsuffix .so,$(BIN)) - -BUILD = $(VBIN) - -#---------------------------------------------------------------------------- -# Include macros and targets -#---------------------------------------------------------------------------- - -include $(ACE_ROOT)/include/makeinclude/wrapper_macros.GNU include $(ACE_ROOT)/include/makeinclude/macros.GNU -include $(ACE_ROOT)/include/makeinclude/rules.common.GNU -include $(ACE_ROOT)/include/makeinclude/rules.nonested.GNU -include $(ACE_ROOT)/include/makeinclude/rules.bin.GNU -include $(ACE_ROOT)/include/makeinclude/rules.local.GNU - -#---------------------------------------------------------------------------- -# Local targets -#---------------------------------------------------------------------------- - -#---------------------------------------------------------------------------- -# Dependencies -#---------------------------------------------------------------------------- - -# IF YOU PUT ANYTHING HERE IT WILL GO AWAY -# DO NOT DELETE THIS LINE -- g++dep uses it. -# DO NOT PUT ANYTHING AFTER THIS LINE, IT WILL GO AWAY. - - -.obj/Transcoder_Test.o .obj/Transcoder_Test.so .shobj/Transcoder_Test.o .shobj/Transcoder_Test.so: Transcoder_Test.cpp \ - $(ACE_ROOT)/ACEXML/common/Transcode.h \ - $(ACE_ROOT)/ace/pre.h \ - $(ACE_ROOT)/ACEXML/common/ACEXML_Export.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - $(ACE_ROOT)/ACEXML/common/XML_Types.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h \ - $(ACE_ROOT)/ace/Trace.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - $(ACE_ROOT)/ace/SString.i \ - $(ACE_ROOT)/ACEXML/common/Transcode.i - -.obj/NamespaceSupport_Test.o .obj/NamespaceSupport_Test.so .shobj/NamespaceSupport_Test.o .shobj/NamespaceSupport_Test.so: NamespaceSupport_Test.cpp \ - $(ACE_ROOT)/ACEXML/common/NamespaceSupport.h \ - $(ACE_ROOT)/ace/pre.h \ - $(ACE_ROOT)/ACEXML/common/ACEXML_Export.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - $(ACE_ROOT)/ACEXML/common/XML_Types.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h \ - $(ACE_ROOT)/ace/Trace.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - $(ACE_ROOT)/ace/SString.i \ - $(ACE_ROOT)/ace/Functor.h \ - $(ACE_ROOT)/ace/Functor.i \ - $(ACE_ROOT)/ace/Functor_T.h \ - $(ACE_ROOT)/ace/Functor_T.i \ - $(ACE_ROOT)/ace/Functor_T.cpp \ - $(ACE_ROOT)/ace/Hash_Map_Manager.h \ - $(ACE_ROOT)/ace/Hash_Map_Manager_T.h \ - $(ACE_ROOT)/ace/Hash_Map_Manager_T.i \ - $(ACE_ROOT)/ace/Hash_Map_Manager_T.cpp \ - $(ACE_ROOT)/ace/Service_Config.h \ - $(ACE_ROOT)/ace/Unbounded_Queue.h \ - $(ACE_ROOT)/ace/Unbounded_Queue.inl \ - $(ACE_ROOT)/ace/Unbounded_Queue.cpp \ - $(ACE_ROOT)/ace/XML_Svc_Conf.h \ - $(ACE_ROOT)/ace/Service_Config.i \ - $(ACE_ROOT)/ace/Reactor.h \ - $(ACE_ROOT)/ace/Handle_Set.h \ - $(ACE_ROOT)/ace/Handle_Set.i \ - $(ACE_ROOT)/ace/Timer_Queue.h \ - $(ACE_ROOT)/ace/Timer_Queue_T.h \ - $(ACE_ROOT)/ace/Test_and_Set.h \ - $(ACE_ROOT)/ace/Test_and_Set.i \ - $(ACE_ROOT)/ace/Test_and_Set.cpp \ - $(ACE_ROOT)/ace/Timer_Queue_T.i \ - $(ACE_ROOT)/ace/Timer_Queue_T.cpp \ - $(ACE_ROOT)/ace/Reactor.i \ - $(ACE_ROOT)/ace/Reactor_Impl.h \ - $(ACE_ROOT)/ace/Svc_Conf_Tokens.h \ - $(ACE_ROOT)/ace/Containers_T.h \ - $(ACE_ROOT)/ace/Containers.h \ - $(ACE_ROOT)/ace/Containers.i \ - $(ACE_ROOT)/ace/Array_Base.h \ - $(ACE_ROOT)/ace/Array_Base.inl \ - $(ACE_ROOT)/ace/Array_Base.cpp \ - $(ACE_ROOT)/ace/Containers_T.i \ - $(ACE_ROOT)/ace/Containers_T.cpp \ - $(ACE_ROOT)/ACEXML/common/NamespaceSupport.i - -.obj/HttpCharStream_Test.o .obj/HttpCharStream_Test.so .shobj/HttpCharStream_Test.o .shobj/HttpCharStream_Test.so: HttpCharStream_Test.cpp \ - $(ACE_ROOT)/ACEXML/common/HttpCharStream.h \ - $(ACE_ROOT)/ace/pre.h \ - $(ACE_ROOT)/ACEXML/common/ACEXML_Export.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - $(ACE_ROOT)/ACEXML/common/CharStream.h \ - $(ACE_ROOT)/ACEXML/common/XML_Types.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h \ - $(ACE_ROOT)/ace/Trace.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - $(ACE_ROOT)/ace/SString.i \ - $(ACE_ROOT)/ACEXML/common/URL_Addr.h \ - $(ACE_ROOT)/ace/INET_Addr.h \ - $(ACE_ROOT)/ace/Addr.h $(ACE_ROOT)/ace/Addr.i \ - $(ACE_ROOT)/ace/INET_Addr.i \ - $(ACE_ROOT)/ACEXML/common/URL_Addr.inl \ - $(ACE_ROOT)/ACEXML/common/Mem_Map_Stream.h \ - $(ACE_ROOT)/ace/SOCK_Stream.h \ - $(ACE_ROOT)/ace/SOCK_IO.h \ - $(ACE_ROOT)/ace/SOCK.h \ - $(ACE_ROOT)/ace/IPC_SAP.h \ - $(ACE_ROOT)/ace/IPC_SAP.i \ - $(ACE_ROOT)/ace/SOCK.i \ - $(ACE_ROOT)/ace/SOCK_IO.i \ - $(ACE_ROOT)/ace/SOCK_Stream.i \ - $(ACE_ROOT)/ace/SOCK_Connector.h \ - $(ACE_ROOT)/ace/SOCK_Connector.i \ - $(ACE_ROOT)/ace/Connector.h \ - $(ACE_ROOT)/ace/Service_Object.h \ - $(ACE_ROOT)/ace/Shared_Object.h \ - $(ACE_ROOT)/ace/Shared_Object.i \ - $(ACE_ROOT)/ace/Svc_Conf_Tokens.h \ - $(ACE_ROOT)/ace/DLL.h \ - $(ACE_ROOT)/ace/Service_Object.i \ - $(ACE_ROOT)/ace/Map_Manager.h \ - $(ACE_ROOT)/ace/Map_Manager.i \ - $(ACE_ROOT)/ace/Map_Manager.cpp \ - $(ACE_ROOT)/ace/Service_Config.h \ - $(ACE_ROOT)/ace/Unbounded_Queue.h \ - $(ACE_ROOT)/ace/Unbounded_Queue.inl \ - $(ACE_ROOT)/ace/Unbounded_Queue.cpp \ - $(ACE_ROOT)/ace/XML_Svc_Conf.h \ - $(ACE_ROOT)/ace/Service_Config.i \ - $(ACE_ROOT)/ace/Reactor.h \ - $(ACE_ROOT)/ace/Handle_Set.h \ - $(ACE_ROOT)/ace/Handle_Set.i \ - $(ACE_ROOT)/ace/Timer_Queue.h \ - $(ACE_ROOT)/ace/Timer_Queue_T.h \ - $(ACE_ROOT)/ace/Test_and_Set.h \ - $(ACE_ROOT)/ace/Test_and_Set.i \ - $(ACE_ROOT)/ace/Test_and_Set.cpp \ - $(ACE_ROOT)/ace/Timer_Queue_T.i \ - $(ACE_ROOT)/ace/Timer_Queue_T.cpp \ - $(ACE_ROOT)/ace/Reactor.i \ - $(ACE_ROOT)/ace/Reactor_Impl.h \ - $(ACE_ROOT)/ace/Strategies_T.h \ - $(ACE_ROOT)/ace/Hash_Map_Manager_T.h \ - $(ACE_ROOT)/ace/Functor.h \ - $(ACE_ROOT)/ace/Functor.i \ - $(ACE_ROOT)/ace/Functor_T.h \ - $(ACE_ROOT)/ace/Functor_T.i \ - $(ACE_ROOT)/ace/Functor_T.cpp \ - $(ACE_ROOT)/ace/Hash_Map_Manager_T.i \ - $(ACE_ROOT)/ace/Hash_Map_Manager_T.cpp \ - $(ACE_ROOT)/ace/Thread_Manager.h \ - $(ACE_ROOT)/ace/Thread_Exit.h \ - $(ACE_ROOT)/ace/Thread_Control.h \ - $(ACE_ROOT)/ace/Thread_Control.inl \ - $(ACE_ROOT)/ace/Containers.h \ - $(ACE_ROOT)/ace/Containers.i \ - $(ACE_ROOT)/ace/Containers_T.h \ - $(ACE_ROOT)/ace/Array_Base.h \ - $(ACE_ROOT)/ace/Array_Base.inl \ - $(ACE_ROOT)/ace/Array_Base.cpp \ - $(ACE_ROOT)/ace/Containers_T.i \ - $(ACE_ROOT)/ace/Containers_T.cpp \ - $(ACE_ROOT)/ace/Singleton.h \ - $(ACE_ROOT)/ace/Singleton.i \ - $(ACE_ROOT)/ace/Singleton.cpp \ - $(ACE_ROOT)/ace/Object_Manager.h \ - $(ACE_ROOT)/ace/Object_Manager.i \ - $(ACE_ROOT)/ace/Managed_Object.h \ - $(ACE_ROOT)/ace/Managed_Object.i \ - $(ACE_ROOT)/ace/Managed_Object.cpp \ - $(ACE_ROOT)/ace/Framework_Component.h \ - $(ACE_ROOT)/ace/Framework_Component.inl \ - $(ACE_ROOT)/ace/Framework_Component_T.h \ - $(ACE_ROOT)/ace/Framework_Component_T.inl \ - $(ACE_ROOT)/ace/Framework_Component_T.cpp \ - $(ACE_ROOT)/ace/Thread_Manager.i \ - $(ACE_ROOT)/ace/Connection_Recycling_Strategy.h \ - $(ACE_ROOT)/ace/Recyclable.h \ - $(ACE_ROOT)/ace/Recyclable.inl \ - $(ACE_ROOT)/ace/Refcountable.h \ - $(ACE_ROOT)/ace/Refcountable.inl \ - $(ACE_ROOT)/ace/Hashable.h \ - $(ACE_ROOT)/ace/Hashable.inl \ - $(ACE_ROOT)/ace/Strategies_T.i \ - $(ACE_ROOT)/ace/Strategies_T.cpp \ - $(ACE_ROOT)/ace/Service_Repository.h \ - $(ACE_ROOT)/ace/Service_Repository.i \ - $(ACE_ROOT)/ace/Service_Types.h \ - $(ACE_ROOT)/ace/Service_Types.i \ - $(ACE_ROOT)/ace/WFMO_Reactor.h \ - $(ACE_ROOT)/ace/Synch_Options.h \ - $(ACE_ROOT)/ace/Synch_Options.i \ - $(ACE_ROOT)/ace/Connector.cpp \ - $(ACE_ROOT)/ace/Svc_Handler.h \ - $(ACE_ROOT)/ace/Task.h $(ACE_ROOT)/ace/Task.i \ - $(ACE_ROOT)/ace/Task_T.h \ - $(ACE_ROOT)/ace/Message_Queue.h \ - $(ACE_ROOT)/ace/Message_Block.h \ - $(ACE_ROOT)/ace/Message_Block.i \ - $(ACE_ROOT)/ace/Message_Block_T.h \ - $(ACE_ROOT)/ace/Message_Block_T.i \ - $(ACE_ROOT)/ace/Message_Block_T.cpp \ - $(ACE_ROOT)/ace/IO_Cntl_Msg.h \ - $(ACE_ROOT)/ace/Message_Queue_T.h \ - $(ACE_ROOT)/ace/Message_Queue_T.i \ - $(ACE_ROOT)/ace/Message_Queue_T.cpp \ - $(ACE_ROOT)/ace/Notification_Strategy.h \ - $(ACE_ROOT)/ace/Notification_Strategy.inl \ - $(ACE_ROOT)/ace/Message_Queue.i \ - $(ACE_ROOT)/ace/Task_T.i \ - $(ACE_ROOT)/ace/Task_T.cpp \ - $(ACE_ROOT)/ace/Module.h \ - $(ACE_ROOT)/ace/Module.i \ - $(ACE_ROOT)/ace/Module.cpp \ - $(ACE_ROOT)/ace/Stream_Modules.h \ - $(ACE_ROOT)/ace/Stream_Modules.cpp \ - $(ACE_ROOT)/ace/Svc_Handler.cpp \ - $(ACE_ROOT)/ace/Dynamic.h \ - $(ACE_ROOT)/ace/Dynamic.i - -.obj/ContentHandler_Test.o .obj/ContentHandler_Test.so .shobj/ContentHandler_Test.o .shobj/ContentHandler_Test.so: ContentHandler_Test.cpp \ - $(ACE_ROOT)/ACEXML/common/DefaultHandler.h \ - $(ACE_ROOT)/ace/pre.h \ - $(ACE_ROOT)/ACEXML/common/ACEXML_Export.h \ - $(ACE_ROOT)/ace/post.h \ - $(ACE_ROOT)/ace/ace_wchar.h \ - $(ACE_ROOT)/ace/ace_wchar.inl \ - $(ACE_ROOT)/ACEXML/common/ContentHandler.h \ - $(ACE_ROOT)/ACEXML/common/Env.h \ - $(ACE_ROOT)/ACEXML/common/XML_Macros.h \ - $(ACE_ROOT)/ace/Exception_Macros.h \ - $(ACE_ROOT)/ACEXML/common/Exception.h \ - $(ACE_ROOT)/ACEXML/common/XML_Types.h \ - $(ACE_ROOT)/ace/OS.h \ - $(ACE_ROOT)/ace/OS_Dirent.h \ - $(ACE_ROOT)/ace/OS_Export.h \ - $(ACE_ROOT)/ace/OS_Errno.h \ - $(ACE_ROOT)/ace/OS_Errno.inl \ - $(ACE_ROOT)/ace/OS_Dirent.inl \ - $(ACE_ROOT)/ace/OS_String.h \ - $(ACE_ROOT)/ace/Basic_Types.h \ - $(ACE_ROOT)/ace/ACE_export.h \ - $(ACE_ROOT)/ace/Basic_Types.i \ - $(ACE_ROOT)/ace/OS_String.inl \ - $(ACE_ROOT)/ace/OS_Memory.h \ - $(ACE_ROOT)/ace/OS_Memory.inl \ - $(ACE_ROOT)/ace/OS_TLI.h \ - $(ACE_ROOT)/ace/OS_TLI.inl \ - $(ACE_ROOT)/ace/Time_Value.h \ - $(ACE_ROOT)/ace/Time_Value.inl \ - $(ACE_ROOT)/ace/Default_Constants.h \ - $(ACE_ROOT)/ace/Global_Macros.h \ - $(ACE_ROOT)/ace/Min_Max.h \ - $(ACE_ROOT)/ace/streams.h \ - $(ACE_ROOT)/ace/Trace.h $(ACE_ROOT)/ace/OS.i \ - $(ACE_ROOT)/ace/SString.h \ - $(ACE_ROOT)/ace/String_Base.h \ - $(ACE_ROOT)/ace/ACE.h \ - $(ACE_ROOT)/ace/Flag_Manip.h \ - $(ACE_ROOT)/ace/Flag_Manip.i \ - $(ACE_ROOT)/ace/Handle_Ops.h \ - $(ACE_ROOT)/ace/Handle_Ops.i \ - $(ACE_ROOT)/ace/Lib_Find.h \ - $(ACE_ROOT)/ace/Lib_Find.i \ - $(ACE_ROOT)/ace/Init_ACE.h \ - $(ACE_ROOT)/ace/Init_ACE.i \ - $(ACE_ROOT)/ace/Sock_Connect.h \ - $(ACE_ROOT)/ace/Sock_Connect.i \ - $(ACE_ROOT)/ace/ACE.i \ - $(ACE_ROOT)/ace/String_Base_Const.h \ - $(ACE_ROOT)/ace/String_Base.i \ - $(ACE_ROOT)/ace/Malloc_Base.h \ - $(ACE_ROOT)/ace/String_Base.cpp \ - $(ACE_ROOT)/ace/Malloc.h \ - $(ACE_ROOT)/ace/Log_Msg.h \ - $(ACE_ROOT)/ace/Log_Priority.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.h \ - $(ACE_ROOT)/ace/OS_Log_Msg_Attributes.inl \ - $(ACE_ROOT)/ace/Malloc.i \ - $(ACE_ROOT)/ace/Malloc_T.h \ - $(ACE_ROOT)/ace/Synch.h $(ACE_ROOT)/ace/Synch.i \ - $(ACE_ROOT)/ace/Synch_T.h \ - $(ACE_ROOT)/ace/Synch_T.i \ - $(ACE_ROOT)/ace/Thread.h \ - $(ACE_ROOT)/ace/Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.h \ - $(ACE_ROOT)/ace/Base_Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread_Adapter.inl \ - $(ACE_ROOT)/ace/Thread.i \ - $(ACE_ROOT)/ace/Synch_T.cpp \ - $(ACE_ROOT)/ace/Malloc_Allocator.h \ - $(ACE_ROOT)/ace/Malloc_Allocator.i \ - $(ACE_ROOT)/ace/Free_List.h \ - $(ACE_ROOT)/ace/Free_List.i \ - $(ACE_ROOT)/ace/Free_List.cpp \ - $(ACE_ROOT)/ace/Malloc_T.i \ - $(ACE_ROOT)/ace/Malloc_T.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.h \ - $(ACE_ROOT)/ace/Event_Handler.h \ - $(ACE_ROOT)/ace/Event_Handler.i \ - $(ACE_ROOT)/ace/Signal.h \ - $(ACE_ROOT)/ace/Signal.i \ - $(ACE_ROOT)/ace/Mem_Map.h \ - $(ACE_ROOT)/ace/Mem_Map.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.h \ - $(ACE_ROOT)/ace/SV_Semaphore_Simple.i \ - $(ACE_ROOT)/ace/SV_Semaphore_Complex.i \ - $(ACE_ROOT)/ace/Unbounded_Set.h \ - $(ACE_ROOT)/ace/Node.h $(ACE_ROOT)/ace/Node.cpp \ - $(ACE_ROOT)/ace/Unbounded_Set.inl \ - $(ACE_ROOT)/ace/Unbounded_Set.cpp \ - $(ACE_ROOT)/ace/Memory_Pool.i \ - $(ACE_ROOT)/ace/Auto_Ptr.h \ - $(ACE_ROOT)/ace/Auto_Ptr.i \ - $(ACE_ROOT)/ace/Auto_Ptr.cpp \ - $(ACE_ROOT)/ace/SString.i \ - $(ACE_ROOT)/ACEXML/common/Exception.i \ - $(ACE_ROOT)/ACEXML/common/Env.i \ - $(ACE_ROOT)/ACEXML/common/SAXExceptions.h \ - $(ACE_ROOT)/ACEXML/common/SAXExceptions.i \ - $(ACE_ROOT)/ACEXML/common/Locator.h \ - $(ACE_ROOT)/ACEXML/common/Attributes.h \ - $(ACE_ROOT)/ACEXML/common/DTDHandler.h \ - $(ACE_ROOT)/ACEXML/common/EntityResolver.h \ - $(ACE_ROOT)/ACEXML/common/InputSource.h \ - $(ACE_ROOT)/ACEXML/common/CharStream.h \ - $(ACE_ROOT)/ACEXML/common/ErrorHandler.h \ - $(ACE_ROOT)/ACEXML/common/DefaultHandler.i \ - $(ACE_ROOT)/ACEXML/common/StrCharStream.h \ - $(ACE_ROOT)/ACEXML/parser/parser/Parser.h \ - $(ACE_ROOT)/ACEXML/parser/parser/Parser_export.h \ - $(ACE_ROOT)/ACEXML/common/XMLReader.h \ - $(ACE_ROOT)/ACEXML/common/LocatorImpl.h \ - $(ACE_ROOT)/ACEXML/common/LocatorImpl.i \ - $(ACE_ROOT)/ACEXML/common/NamespaceSupport.h \ - $(ACE_ROOT)/ace/Functor.h \ - $(ACE_ROOT)/ace/Functor.i \ - $(ACE_ROOT)/ace/Functor_T.h \ - $(ACE_ROOT)/ace/Functor_T.i \ - $(ACE_ROOT)/ace/Functor_T.cpp \ - $(ACE_ROOT)/ace/Hash_Map_Manager.h \ - $(ACE_ROOT)/ace/Hash_Map_Manager_T.h \ - $(ACE_ROOT)/ace/Hash_Map_Manager_T.i \ - $(ACE_ROOT)/ace/Hash_Map_Manager_T.cpp \ - $(ACE_ROOT)/ace/Service_Config.h \ - $(ACE_ROOT)/ace/Unbounded_Queue.h \ - $(ACE_ROOT)/ace/Unbounded_Queue.inl \ - $(ACE_ROOT)/ace/Unbounded_Queue.cpp \ - $(ACE_ROOT)/ace/XML_Svc_Conf.h \ - $(ACE_ROOT)/ace/Service_Config.i \ - $(ACE_ROOT)/ace/Reactor.h \ - $(ACE_ROOT)/ace/Handle_Set.h \ - $(ACE_ROOT)/ace/Handle_Set.i \ - $(ACE_ROOT)/ace/Timer_Queue.h \ - $(ACE_ROOT)/ace/Timer_Queue_T.h \ - $(ACE_ROOT)/ace/Test_and_Set.h \ - $(ACE_ROOT)/ace/Test_and_Set.i \ - $(ACE_ROOT)/ace/Test_and_Set.cpp \ - $(ACE_ROOT)/ace/Timer_Queue_T.i \ - $(ACE_ROOT)/ace/Timer_Queue_T.cpp \ - $(ACE_ROOT)/ace/Reactor.i \ - $(ACE_ROOT)/ace/Reactor_Impl.h \ - $(ACE_ROOT)/ace/Svc_Conf_Tokens.h \ - $(ACE_ROOT)/ace/Containers_T.h \ - $(ACE_ROOT)/ace/Containers.h \ - $(ACE_ROOT)/ace/Containers.i \ - $(ACE_ROOT)/ace/Array_Base.h \ - $(ACE_ROOT)/ace/Array_Base.inl \ - $(ACE_ROOT)/ace/Array_Base.cpp \ - $(ACE_ROOT)/ace/Containers_T.i \ - $(ACE_ROOT)/ace/Containers_T.cpp \ - $(ACE_ROOT)/ACEXML/common/NamespaceSupport.i \ - $(ACE_ROOT)/ace/Obstack.h \ - $(ACE_ROOT)/ace/Obstack_T.h \ - $(ACE_ROOT)/ace/Obchunk.h \ - $(ACE_ROOT)/ace/Obchunk.i \ - $(ACE_ROOT)/ace/Obstack_T.i \ - $(ACE_ROOT)/ace/Obstack_T.cpp \ - $(ACE_ROOT)/ACEXML/parser/parser/Entity_Manager.h \ - $(ACE_ROOT)/ACEXML/parser/parser/Entity_Manager.i \ - $(ACE_ROOT)/ACEXML/parser/parser/Parser.i - -# IF YOU PUT ANYTHING HERE IT WILL GO AWAY +TARGETS_NESTED := $(TARGETS_NESTED:.nested=) +MFILES = \ + Makefile.Transcoder_Test \ + Makefile.NamespaceSupport_Test \ + Makefile.HttpCharStream_Test \ + Makefile.ContentHandler_Test + +$(TARGETS_NESTED): +ifneq (Windows,$(findstring Windows,$(OS))) + @for file in $(MFILES); do \ + $(MAKE) -f `basename $$file` -C `dirname $$file` $(@); \ + done +else + -@cmd /c "$(MAKE) -f Makefile.Transcoder_Test -C . $(@)" + -@cmd /c "$(MAKE) -f Makefile.NamespaceSupport_Test -C . $(@)" + -@cmd /c "$(MAKE) -f Makefile.HttpCharStream_Test -C . $(@)" + -@cmd /c "$(MAKE) -f Makefile.ContentHandler_Test -C . $(@)" +endif diff --git a/ACEXML/tests/Makefile.ContentHandler_Test.bor b/ACEXML/tests/Makefile.ContentHandler_Test.bor new file mode 100644 index 00000000000..1a20c46f593 --- /dev/null +++ b/ACEXML/tests/Makefile.ContentHandler_Test.bor @@ -0,0 +1,47 @@ +# Makefile for building the ContentHandler_Test exe with Borland C++ Builder + +NAME = ContentHandler_Test + +NAME = ContentHandler_Test + + +OBJFILES = \ + $(OBJDIR)\ContentHandler_Test.obj + +EXTERNAL_LIBS = \ + \ + +LFLAGS = \ + -j..\..\ACEXML\common\$(CONFIG_SUBDIR) -j..\..\ACEXML\common \ + -L..\..\ACEXML\common\$(CONFIG_SUBDIR) -L..\..\ACEXML\common \ + -j..\..\ACEXML\parser\parser\$(CONFIG_SUBDIR) -j..\..\ACEXML\parser\parser \ + -L..\..\ACEXML\parser\parser\$(CONFIG_SUBDIR) -L..\..\ACEXML\parser\parser \ + -j..\..\ace\$(CONFIG_SUBDIR) -j..\..\ace \ + -L..\..\ace\$(CONFIG_SUBDIR) -L..\..\ace \ + -j$(CORE_BINDIR) \ + -L$(CORE_BINDIR) + +LIBFILES = \ + ACEXML_Parser$(LIB_DECORATOR).lib \ + ACEXML$(LIB_DECORATOR).lib \ + ACE$(LIB_DECORATOR).lib \ + $(EXTERNAL_LIBS) + + + +!ifdef STATIC +LIB_FLAGS = -DACE_AS_STATIC_LIBS +DLL_FLAGS = +!else +LIB_FLAGS = +DLL_FLAGS = +!endif + +CFLAGS = \ + -I..\.. \ + $(LIB_FLAGS) \ + $(DLL_FLAGS) + +CPPDIR = . + +!include <$(ACE_ROOT)\include\makeinclude\build_exe.bor> diff --git a/ACEXML/tests/Makefile.HttpCharStream_Test b/ACEXML/tests/Makefile.HttpCharStream_Test new file mode 100644 index 00000000000..a73727b16ba --- /dev/null +++ b/ACEXML/tests/Makefile.HttpCharStream_Test @@ -0,0 +1,55 @@ +#---------------------------------------------------------------------------- +# GNU Makefile +#---------------------------------------------------------------------------- +MAKEFILE = Makefile.HttpCharStream_Test +DEPENDENCY_FILE = .depend.Makefile.HttpCharStream_Test +BIN_UNCHECKED = HttpCharStream_Test + + + +FILES = \ + HttpCharStream_Test +#---------------------------------------------------------------------------- +# Include macros and targets +#---------------------------------------------------------------------------- + +include $(ACE_ROOT)/include/makeinclude/wrapper_macros.GNU + +BIN = $(BIN_UNCHECKED) + +OBJS = $(addsuffix .o, $(notdir $(FILES))) +SRC = $(addsuffix .cpp, $(FILES)) +ACELIB = -lACE + +include $(ACE_ROOT)/include/makeinclude/macros.GNU +include $(ACE_ROOT)/include/makeinclude/rules.common.GNU +include $(ACE_ROOT)/include/makeinclude/rules.nonested.GNU +include $(ACE_ROOT)/include/makeinclude/rules.local.GNU + +CPPFLAGS += -I../.. + + +ifeq ($(static_libs),1) + ifneq ($(LIB),) + CPPFLAGS += -DACE_AS_STATIC_LIBS + endif +endif + + +LDFLAGS += -L../../ACEXML/common -L../../ACEXML/parser/parser -L../../ace + + + +LDLIBS = -lACEXML_Parser -lACEXML +#---------------------------------------------------------------------------- +# Local targets +#---------------------------------------------------------------------------- + +$(BIN): $(addprefix $(VDIR), $(OBJS)) + $(LINK.cc) $(LDFLAGS) $(CC_OUTPUT_FLAG) $@ $^ $(VLDLIBS) $(POSTLINK) + +realclean: clean +ifneq ($(GENERATED_DIRTY),) + -$(RM) -r $(GENERATED_DIRTY) +endif + diff --git a/ACEXML/tests/Makefile.HttpCharStream_Test.bor b/ACEXML/tests/Makefile.HttpCharStream_Test.bor new file mode 100644 index 00000000000..e262670146e --- /dev/null +++ b/ACEXML/tests/Makefile.HttpCharStream_Test.bor @@ -0,0 +1,47 @@ +# Makefile for building the HttpCharStream_Test exe with Borland C++ Builder + +NAME = HttpCharStream_Test + +NAME = HttpCharStream_Test + + +OBJFILES = \ + $(OBJDIR)\HttpCharStream_Test.obj + +EXTERNAL_LIBS = \ + \ + +LFLAGS = \ + -j..\..\ACEXML\common\$(CONFIG_SUBDIR) -j..\..\ACEXML\common \ + -L..\..\ACEXML\common\$(CONFIG_SUBDIR) -L..\..\ACEXML\common \ + -j..\..\ACEXML\parser\parser\$(CONFIG_SUBDIR) -j..\..\ACEXML\parser\parser \ + -L..\..\ACEXML\parser\parser\$(CONFIG_SUBDIR) -L..\..\ACEXML\parser\parser \ + -j..\..\ace\$(CONFIG_SUBDIR) -j..\..\ace \ + -L..\..\ace\$(CONFIG_SUBDIR) -L..\..\ace \ + -j$(CORE_BINDIR) \ + -L$(CORE_BINDIR) + +LIBFILES = \ + ACEXML_Parser$(LIB_DECORATOR).lib \ + ACEXML$(LIB_DECORATOR).lib \ + ACE$(LIB_DECORATOR).lib \ + $(EXTERNAL_LIBS) + + + +!ifdef STATIC +LIB_FLAGS = -DACE_AS_STATIC_LIBS +DLL_FLAGS = +!else +LIB_FLAGS = +DLL_FLAGS = +!endif + +CFLAGS = \ + -I..\.. \ + $(LIB_FLAGS) \ + $(DLL_FLAGS) + +CPPDIR = . + +!include <$(ACE_ROOT)\include\makeinclude\build_exe.bor> diff --git a/ACEXML/tests/Makefile.NamespaceSupport_Test b/ACEXML/tests/Makefile.NamespaceSupport_Test new file mode 100644 index 00000000000..07fe1c5997f --- /dev/null +++ b/ACEXML/tests/Makefile.NamespaceSupport_Test @@ -0,0 +1,55 @@ +#---------------------------------------------------------------------------- +# GNU Makefile +#---------------------------------------------------------------------------- +MAKEFILE = Makefile.NamespaceSupport_Test +DEPENDENCY_FILE = .depend.Makefile.NamespaceSupport_Test +BIN_UNCHECKED = NamespaceSupport_Test + + + +FILES = \ + NamespaceSupport_Test +#---------------------------------------------------------------------------- +# Include macros and targets +#---------------------------------------------------------------------------- + +include $(ACE_ROOT)/include/makeinclude/wrapper_macros.GNU + +BIN = $(BIN_UNCHECKED) + +OBJS = $(addsuffix .o, $(notdir $(FILES))) +SRC = $(addsuffix .cpp, $(FILES)) +ACELIB = -lACE + +include $(ACE_ROOT)/include/makeinclude/macros.GNU +include $(ACE_ROOT)/include/makeinclude/rules.common.GNU +include $(ACE_ROOT)/include/makeinclude/rules.nonested.GNU +include $(ACE_ROOT)/include/makeinclude/rules.local.GNU + +CPPFLAGS += -I../.. + + +ifeq ($(static_libs),1) + ifneq ($(LIB),) + CPPFLAGS += -DACE_AS_STATIC_LIBS + endif +endif + + +LDFLAGS += -L../../ACEXML/common -L../../ACEXML/parser/parser -L../../ace + + + +LDLIBS = -lACEXML_Parser -lACEXML +#---------------------------------------------------------------------------- +# Local targets +#---------------------------------------------------------------------------- + +$(BIN): $(addprefix $(VDIR), $(OBJS)) + $(LINK.cc) $(LDFLAGS) $(CC_OUTPUT_FLAG) $@ $^ $(VLDLIBS) $(POSTLINK) + +realclean: clean +ifneq ($(GENERATED_DIRTY),) + -$(RM) -r $(GENERATED_DIRTY) +endif + diff --git a/ACEXML/tests/Makefile.NamespaceSupport_Test.bor b/ACEXML/tests/Makefile.NamespaceSupport_Test.bor new file mode 100644 index 00000000000..970bd5da4d1 --- /dev/null +++ b/ACEXML/tests/Makefile.NamespaceSupport_Test.bor @@ -0,0 +1,47 @@ +# Makefile for building the NamespaceSupport_Test exe with Borland C++ Builder + +NAME = NamespaceSupport_Test + +NAME = NamespaceSupport_Test + + +OBJFILES = \ + $(OBJDIR)\NamespaceSupport_Test.obj + +EXTERNAL_LIBS = \ + \ + +LFLAGS = \ + -j..\..\ACEXML\common\$(CONFIG_SUBDIR) -j..\..\ACEXML\common \ + -L..\..\ACEXML\common\$(CONFIG_SUBDIR) -L..\..\ACEXML\common \ + -j..\..\ACEXML\parser\parser\$(CONFIG_SUBDIR) -j..\..\ACEXML\parser\parser \ + -L..\..\ACEXML\parser\parser\$(CONFIG_SUBDIR) -L..\..\ACEXML\parser\parser \ + -j..\..\ace\$(CONFIG_SUBDIR) -j..\..\ace \ + -L..\..\ace\$(CONFIG_SUBDIR) -L..\..\ace \ + -j$(CORE_BINDIR) \ + -L$(CORE_BINDIR) + +LIBFILES = \ + ACEXML_Parser$(LIB_DECORATOR).lib \ + ACEXML$(LIB_DECORATOR).lib \ + ACE$(LIB_DECORATOR).lib \ + $(EXTERNAL_LIBS) + + + +!ifdef STATIC +LIB_FLAGS = -DACE_AS_STATIC_LIBS +DLL_FLAGS = +!else +LIB_FLAGS = +DLL_FLAGS = +!endif + +CFLAGS = \ + -I..\.. \ + $(LIB_FLAGS) \ + $(DLL_FLAGS) + +CPPDIR = . + +!include <$(ACE_ROOT)\include\makeinclude\build_exe.bor> diff --git a/ACEXML/tests/Makefile.Transcoder_Test b/ACEXML/tests/Makefile.Transcoder_Test new file mode 100644 index 00000000000..04c74e8d766 --- /dev/null +++ b/ACEXML/tests/Makefile.Transcoder_Test @@ -0,0 +1,55 @@ +#---------------------------------------------------------------------------- +# GNU Makefile +#---------------------------------------------------------------------------- +MAKEFILE = Makefile.Transcoder_Test +DEPENDENCY_FILE = .depend.Makefile.Transcoder_Test +BIN_UNCHECKED = Transcoder_Test + + + +FILES = \ + Transcoder_Test +#---------------------------------------------------------------------------- +# Include macros and targets +#---------------------------------------------------------------------------- + +include $(ACE_ROOT)/include/makeinclude/wrapper_macros.GNU + +BIN = $(BIN_UNCHECKED) + +OBJS = $(addsuffix .o, $(notdir $(FILES))) +SRC = $(addsuffix .cpp, $(FILES)) +ACELIB = -lACE + +include $(ACE_ROOT)/include/makeinclude/macros.GNU +include $(ACE_ROOT)/include/makeinclude/rules.common.GNU +include $(ACE_ROOT)/include/makeinclude/rules.nonested.GNU +include $(ACE_ROOT)/include/makeinclude/rules.local.GNU + +CPPFLAGS += -I../.. + + +ifeq ($(static_libs),1) + ifneq ($(LIB),) + CPPFLAGS += -DACE_AS_STATIC_LIBS + endif +endif + + +LDFLAGS += -L../../ACEXML/common -L../../ACEXML/parser/parser -L../../ace + + + +LDLIBS = -lACEXML_Parser -lACEXML +#---------------------------------------------------------------------------- +# Local targets +#---------------------------------------------------------------------------- + +$(BIN): $(addprefix $(VDIR), $(OBJS)) + $(LINK.cc) $(LDFLAGS) $(CC_OUTPUT_FLAG) $@ $^ $(VLDLIBS) $(POSTLINK) + +realclean: clean +ifneq ($(GENERATED_DIRTY),) + -$(RM) -r $(GENERATED_DIRTY) +endif + diff --git a/ACEXML/tests/Makefile.Transcoder_Test.bor b/ACEXML/tests/Makefile.Transcoder_Test.bor new file mode 100644 index 00000000000..bb4b782a725 --- /dev/null +++ b/ACEXML/tests/Makefile.Transcoder_Test.bor @@ -0,0 +1,47 @@ +# Makefile for building the Transcoder_Test exe with Borland C++ Builder + +NAME = Transcoder_Test + +NAME = Transcoder_Test + + +OBJFILES = \ + $(OBJDIR)\Transcoder_Test.obj + +EXTERNAL_LIBS = \ + \ + +LFLAGS = \ + -j..\..\ACEXML\common\$(CONFIG_SUBDIR) -j..\..\ACEXML\common \ + -L..\..\ACEXML\common\$(CONFIG_SUBDIR) -L..\..\ACEXML\common \ + -j..\..\ACEXML\parser\parser\$(CONFIG_SUBDIR) -j..\..\ACEXML\parser\parser \ + -L..\..\ACEXML\parser\parser\$(CONFIG_SUBDIR) -L..\..\ACEXML\parser\parser \ + -j..\..\ace\$(CONFIG_SUBDIR) -j..\..\ace \ + -L..\..\ace\$(CONFIG_SUBDIR) -L..\..\ace \ + -j$(CORE_BINDIR) \ + -L$(CORE_BINDIR) + +LIBFILES = \ + ACEXML_Parser$(LIB_DECORATOR).lib \ + ACEXML$(LIB_DECORATOR).lib \ + ACE$(LIB_DECORATOR).lib \ + $(EXTERNAL_LIBS) + + + +!ifdef STATIC +LIB_FLAGS = -DACE_AS_STATIC_LIBS +DLL_FLAGS = +!else +LIB_FLAGS = +DLL_FLAGS = +!endif + +CFLAGS = \ + -I..\.. \ + $(LIB_FLAGS) \ + $(DLL_FLAGS) + +CPPDIR = . + +!include <$(ACE_ROOT)\include\makeinclude\build_exe.bor> diff --git a/ACEXML/tests/Makefile.bor b/ACEXML/tests/Makefile.bor index d2bc13a9dc2..057b1dfb049 100644 --- a/ACEXML/tests/Makefile.bor +++ b/ACEXML/tests/Makefile.bor @@ -1,26 +1,32 @@ -# -# $Id$ -# Makefile for building the ACE XML tests -# +#---------------------------------------------------------------------------- +# Borland Workspace +#---------------------------------------------------------------------------- -NAMES = \ - NamespaceSupport_Test \ - Transcoder_Test \ - HttpCharStream_Test \ - ContentHandler_Test +!include <$(ACE_ROOT)\include\makeinclude\make_flags.bor> -OBJFILES = $(OBJDIR)\$(NAME).obj +all: + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.Transcoder_Test.bor all + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.NamespaceSupport_Test.bor all + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.HttpCharStream_Test.bor all + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ContentHandler_Test.bor all -CFLAGS = \ - $(ACE_CFLAGS) \ - $(ACE_XML_CFLAGS) +clean: + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.Transcoder_Test.bor clean + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.NamespaceSupport_Test.bor clean + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.HttpCharStream_Test.bor clean + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ContentHandler_Test.bor clean -CPPDIR = . +realclean: + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.Transcoder_Test.bor realclean + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.NamespaceSupport_Test.bor realclean + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.HttpCharStream_Test.bor realclean + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ContentHandler_Test.bor realclean -LIBFILES = \ - $(ACE_LIB) \ - $(ACE_XML_PARSER_LIB) \ - $(ACE_XML_LIB) +install: + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.Transcoder_Test.bor install + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.NamespaceSupport_Test.bor install + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.HttpCharStream_Test.bor install + $(MAKE) -$(MAKEFLAGS) $(MAKE_FLAGS) -f Makefile.ContentHandler_Test.bor install -!include <$(ACE_ROOT)\include\makeinclude\recurse.bor> -!include <$(ACE_ROOT)\include\makeinclude\build_exe.bor> +regenerate: + D:\Perl\bin\perl.exe D:\ACE_wrappers\bin\mwc.pl -type borland -recurse diff --git a/ACEXML/tests/NamespaceSupport_Test.dsp b/ACEXML/tests/NamespaceSupport_Test.dsp index c6efd71974a..440670aa192 100644 --- a/ACEXML/tests/NamespaceSupport_Test.dsp +++ b/ACEXML/tests/NamespaceSupport_Test.dsp @@ -1,25 +1,26 @@ -# Microsoft Developer Studio Project File - Name="NamespaceSupport_Test" - Package Owner=<4>
+# Microsoft Developer Studio Project File - Name="NamespaceSupport_Test EXE" - Package Owner=<4>
# Microsoft Developer Studio Generated Build File, Format Version 6.00
# ** DO NOT EDIT **
# TARGTYPE "Win32 (x86) Console Application" 0x0103
-CFG=NamespaceSupport_Test - Win32 Debug
+CFG=NamespaceSupport_Test EXE - Win32 Debug
!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
+!MESSAGE run the tool that generated this project file and specify the
+!MESSAGE nmake output type. You can then use the following command:
+!MESSAGE
!MESSAGE NMAKE /f "NamespaceSupport_Test.mak".
-!MESSAGE
+!MESSAGE
!MESSAGE You can specify a configuration when running NMAKE
!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "NamespaceSupport_Test.mak" CFG="NamespaceSupport_Test - Win32 Debug"
-!MESSAGE
+!MESSAGE
+!MESSAGE NMAKE /f "NamespaceSupport_Test.mak" CFG="NamespaceSupport_Test EXE - Win32 Debug"
+!MESSAGE
!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "NamespaceSupport_Test - Win32 Release" (based on "Win32 (x86) Console Application")
-!MESSAGE "NamespaceSupport_Test - Win32 Debug" (based on "Win32 (x86) Console Application")
-!MESSAGE
+!MESSAGE
+!MESSAGE "NamespaceSupport_Test EXE - Win32 Release" (based on "Win32 (x86) Console Application")
+!MESSAGE "NamespaceSupport_Test EXE - Win32 Debug" (based on "Win32 (x86) Console Application")
+!MESSAGE
# Begin Project
# PROP AllowPerConfigDependencies 0
@@ -28,77 +29,49 @@ CFG=NamespaceSupport_Test - Win32 Debug CPP=cl.exe
RSC=rc.exe
-!IF "$(CFG)" == "NamespaceSupport_Test - Win32 Release"
+!IF "$(CFG)" == "NamespaceSupport_Test EXE - Win32 Release"
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release"
-# PROP BASE Intermediate_Dir "Release"
-# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 0
# PROP Output_Dir "Release"
-# PROP Intermediate_Dir "Release"
-# PROP Ignore_Export_Lib 0
+# PROP Intermediate_Dir "Release\NamespaceSupport_Test"
# PROP Target_Dir ""
-# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "../.." /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
+# ADD CPP /nologo /W3 /GX /O2 /MD /GR /I "..\.." /D NDEBUG=1 /D WIN32=1 /D _CONSOLE=1 /FD /c
# SUBTRACT CPP /YX
-# ADD BASE RSC /l 0x409 /d "NDEBUG"
-# ADD RSC /l 0x409 /d "NDEBUG"
+# ADD RSC /l 0x409 /d NDEBUG=1 /i "..\.."
BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
+# ADD BSC32 /nologo
LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386
-# ADD LINK32 ace.lib ACEXML.lib /nologo /subsystem:console /machine:I386 /libpath:"..\..\ace" /libpath:"..\Common"
+# ADD LINK32 advapi32.lib user32.lib /INCREMENTAL:NO ACEXML_Parser.lib ACEXML.lib ACE.lib /libpath:"..\..\ACEXML\common" /libpath:"..\..\ACEXML\parser\parser" /libpath:"..\..\ace" /nologo /version:5.3.1 /subsystem:console /pdb:"Release\NamespaceSupport_Test.pdb" /machine:I386 /out:"Release\NamespaceSupport_Test.exe"
-!ELSEIF "$(CFG)" == "NamespaceSupport_Test - Win32 Debug"
+!ELSEIF "$(CFG)" == "NamespaceSupport_Test EXE - Win32 Debug"
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug"
-# PROP BASE Intermediate_Dir "Debug"
-# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 1
-# PROP Output_Dir ""
-# PROP Intermediate_Dir "Debug"
-# PROP Ignore_Export_Lib 0
+# PROP Output_Dir "."
+# PROP Intermediate_Dir "Debug\NamespaceSupport_Test"
# PROP Target_Dir ""
-# ADD BASE CPP /nologo /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /Zi /Od /I "../.." /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
+# ADD CPP /nologo /W3 /Gm /GX /Zi /Od /MDd /GR /Gy /I "..\.." /D _DEBUG=1 /D WIN32=1 /D _CONSOLE=1 /FD /c
# SUBTRACT CPP /YX
-# ADD BASE RSC /l 0x409 /d "_DEBUG"
-# ADD RSC /l 0x409 /d "_DEBUG"
+# ADD RSC /l 0x409 /d _DEBUG=1 /i "..\.."
BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
+# ADD BSC32 /nologo
LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 aced.lib ACEXMLd.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept /libpath:"..\..\ace" /libpath:"..\Common"
+# ADD LINK32 advapi32.lib user32.lib /INCREMENTAL:NO ACEXML_Parserd.lib ACEXMLd.lib ACEd.lib /libpath:"..\..\ACEXML\common" /libpath:"..\..\ACEXML\parser\parser" /libpath:"..\..\ace" /nologo /version:5.3.1 /subsystem:console /pdb:".\NamespaceSupport_Test.pdb" /debug /machine:I386 /out:".\NamespaceSupport_Test.exe"
-!ENDIF
+!ENDIF
# Begin Target
-# Name "NamespaceSupport_Test - Win32 Release"
-# Name "NamespaceSupport_Test - Win32 Debug"
+# Name "NamespaceSupport_Test EXE - Win32 Release"
+# Name "NamespaceSupport_Test EXE - Win32 Debug"
# Begin Group "Source Files"
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
+# PROP Default_Filter "cpp;cxx;c"
# Begin Source File
SOURCE=.\NamespaceSupport_Test.cpp
# End Source File
# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# End Group
-# Begin Group "Resource Files"
-
-# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
-# End Group
# End Target
# End Project
diff --git a/ACEXML/tests/Transcoder_Test.dsp b/ACEXML/tests/Transcoder_Test.dsp index 3c329c92e51..927a0a92e6c 100644 --- a/ACEXML/tests/Transcoder_Test.dsp +++ b/ACEXML/tests/Transcoder_Test.dsp @@ -1,25 +1,26 @@ -# Microsoft Developer Studio Project File - Name="Transcoder_Test" - Package Owner=<4>
+# Microsoft Developer Studio Project File - Name="Transcoder_Test EXE" - Package Owner=<4>
# Microsoft Developer Studio Generated Build File, Format Version 6.00
# ** DO NOT EDIT **
# TARGTYPE "Win32 (x86) Console Application" 0x0103
-CFG=Transcoder_Test - Win32 Debug
+CFG=Transcoder_Test EXE - Win32 Debug
!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
+!MESSAGE run the tool that generated this project file and specify the
+!MESSAGE nmake output type. You can then use the following command:
+!MESSAGE
!MESSAGE NMAKE /f "Transcoder_Test.mak".
-!MESSAGE
+!MESSAGE
!MESSAGE You can specify a configuration when running NMAKE
!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "Transcoder_Test.mak" CFG="Transcoder_Test - Win32 Debug"
-!MESSAGE
+!MESSAGE
+!MESSAGE NMAKE /f "Transcoder_Test.mak" CFG="Transcoder_Test EXE - Win32 Debug"
+!MESSAGE
!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "Transcoder_Test - Win32 Release" (based on "Win32 (x86) Console Application")
-!MESSAGE "Transcoder_Test - Win32 Debug" (based on "Win32 (x86) Console Application")
-!MESSAGE
+!MESSAGE
+!MESSAGE "Transcoder_Test EXE - Win32 Release" (based on "Win32 (x86) Console Application")
+!MESSAGE "Transcoder_Test EXE - Win32 Debug" (based on "Win32 (x86) Console Application")
+!MESSAGE
# Begin Project
# PROP AllowPerConfigDependencies 0
@@ -28,77 +29,49 @@ CFG=Transcoder_Test - Win32 Debug CPP=cl.exe
RSC=rc.exe
-!IF "$(CFG)" == "Transcoder_Test - Win32 Release"
+!IF "$(CFG)" == "Transcoder_Test EXE - Win32 Release"
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release"
-# PROP BASE Intermediate_Dir "Release"
-# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 0
# PROP Output_Dir "Release"
-# PROP Intermediate_Dir "Release"
-# PROP Ignore_Export_Lib 0
+# PROP Intermediate_Dir "Release\Transcoder_Test"
# PROP Target_Dir ""
-# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "../.." /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
+# ADD CPP /nologo /W3 /GX /O2 /MD /GR /I "..\.." /D NDEBUG=1 /D WIN32=1 /D _CONSOLE=1 /FD /c
# SUBTRACT CPP /YX
-# ADD BASE RSC /l 0x409 /d "NDEBUG"
-# ADD RSC /l 0x409 /d "NDEBUG"
+# ADD RSC /l 0x409 /d NDEBUG=1 /i "..\.."
BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
+# ADD BSC32 /nologo
LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386
-# ADD LINK32 ace.lib ACEXML.lib /nologo /subsystem:console /machine:I386 /libpath:"..\..\ace" /libpath:"..\Common"
+# ADD LINK32 advapi32.lib user32.lib /INCREMENTAL:NO ACEXML_Parser.lib ACEXML.lib ACE.lib /libpath:"..\..\ACEXML\common" /libpath:"..\..\ACEXML\parser\parser" /libpath:"..\..\ace" /nologo /version:5.3.1 /subsystem:console /pdb:"Release\Transcoder_Test.pdb" /machine:I386 /out:"Release\Transcoder_Test.exe"
-!ELSEIF "$(CFG)" == "Transcoder_Test - Win32 Debug"
+!ELSEIF "$(CFG)" == "Transcoder_Test EXE - Win32 Debug"
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug"
-# PROP BASE Intermediate_Dir "Debug"
-# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 1
-# PROP Output_Dir ""
-# PROP Intermediate_Dir "Debug"
-# PROP Ignore_Export_Lib 0
+# PROP Output_Dir "."
+# PROP Intermediate_Dir "Debug\Transcoder_Test"
# PROP Target_Dir ""
-# ADD BASE CPP /nologo /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /Zi /Od /I "../.." /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /FD /c
+# ADD CPP /nologo /W3 /Gm /GX /Zi /Od /MDd /GR /Gy /I "..\.." /D _DEBUG=1 /D WIN32=1 /D _CONSOLE=1 /FD /c
# SUBTRACT CPP /YX
-# ADD BASE RSC /l 0x409 /d "_DEBUG"
-# ADD RSC /l 0x409 /d "_DEBUG"
+# ADD RSC /l 0x409 /d _DEBUG=1 /i "..\.."
BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
+# ADD BSC32 /nologo
LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 aced.lib ACEXMLd.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept /libpath:"..\..\ace" /libpath:"..\Common"
+# ADD LINK32 advapi32.lib user32.lib /INCREMENTAL:NO ACEXML_Parserd.lib ACEXMLd.lib ACEd.lib /libpath:"..\..\ACEXML\common" /libpath:"..\..\ACEXML\parser\parser" /libpath:"..\..\ace" /nologo /version:5.3.1 /subsystem:console /pdb:".\Transcoder_Test.pdb" /debug /machine:I386 /out:".\Transcoder_Test.exe"
-!ENDIF
+!ENDIF
# Begin Target
-# Name "Transcoder_Test - Win32 Release"
-# Name "Transcoder_Test - Win32 Debug"
+# Name "Transcoder_Test EXE - Win32 Release"
+# Name "Transcoder_Test EXE - Win32 Debug"
# Begin Group "Source Files"
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
+# PROP Default_Filter "cpp;cxx;c"
# Begin Source File
SOURCE=.\Transcoder_Test.cpp
# End Source File
# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# End Group
-# Begin Group "Resource Files"
-
-# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
-# End Group
# End Target
# End Project
|