&XercesCName; comes with sample applications that
demonstrate salient features of the parser. They are simple
applications written on top of the SAX and DOM APIs provided by
the parser. Sample XML data files are provided in the
samples/data
directory.
The sample applications are dependent on the &XercesCName; shared library
(and could also depend on the ICU library if you built &XercesCName; with ICU).
Therefore, on Windows platforms you must make sure that your PATH
environment variable is set properly to pick up these shared libraries at
runtime.
On UNIX platforms you must ensure that LD_LIBRARY_PATH
environment variable is set properly to pick up the shared libraries at
runtime. (UNIX gurus will understand here that LD_LIBRARY_PATH
actually translates to LD_LIBRARY_PATH
on Solaris and Linux,
SHLIB_PATH
on HP-UX, DYLD_LIBRARY_PATH
on Mac OS X,
and LIBPATH
on AIX).
On both Windows and UNIX platforms, if the parser is built with the ICU
message loader or message catalog loader, then you may need to set another
environment variable, XERCESC_NLS_HOME
, to point to the
&XercesC3SrcInstallDir;/msg directory, which is where the message
files reside.
Once you have set up the environment variables, you can run the samples by opening a command window (or your shell prompt for UNIX environments).