/** @mainpage
<h1> TinyXml </h1>
TinyXml is a simple, small, C++ XML parser that can be easily
integrating into other programs.
<h2> What it does. </h2>
In brief, TinyXml parses an XML document, and builds from that a
Document Object Model (DOM) that can be read, modified, and saved.
XML stands for "eXtensible Markup Language." It allows you to create
your own document markups. Where HTML does a very good job of marking
documents for browsers, XML allows you to define any kind of document
markup, for example a document that describes a "to do" list for an
organizer application. XML is a very structured and convenient format.
All those random file formats created to store application data can
all be replaced with XML. One parser for everything.
The best place for the complete, correct, and quite frankly hard to
read spec is at <a href="http://www.w3.org/TR/2004/REC-xml-20040204/">
http://www.w3.org/TR/2004/REC-xml-20040204/</a>. An intro to XML
(that I really like) can be found at
<a href="http://skew.org/xml/tutorial/">http://skew.org/xml/tutorial</a>.
There are different ways to access and interact with XML data.
TinyXml uses a Document Object Model (DOM), meaning the XML data is parsed
into a C++ objects that can be browsed and manipulated, and then
written to disk or another output stream. You can also construct an XML document from
scratch with C++ objects and write this to disk or another output
stream.
TinyXml is designed to be easy and fast to learn. It is two headers
and four cpp files. Simply add these to your project and off you go.
There is an example file - xmltest.cpp - to get you started.
TinyXml is released under the ZLib license,
so you can use it in open source or commercial code. The details
of the license are at the top of every source file.
TinyXml attempts to be a flexible parser, but with truly correct and
compliant XML output. TinyXml should compile on any reasonably C++
compliant system. It does not rely on exceptions or RTTI. It can be
compiled with or without STL support. TinyXml fully supports
the UTF-8 encoding, and the first 64k character entities.
<h2> What it doesn't do. </h2>
It doesnt parse or use DTDs (Document Type Definitions) or XSLs
(eXtensible Stylesheet Language.) There are other parsers out there
(check out www.sourceforge.org, search for XML) that are much more fully
featured. But they are also much bigger, take longer to set up in
your project, have a higher learning curve, and often have a more
restrictive license. If you are working with browsers or have more
complete XML needs, TinyXml is not the parser for you.
The following DTD syntax will not parse at this time in TinyXml:
@verbatim
<!DOCTYPE Archiv [
<!ELEMENT Comment (#PCDATA)>
]>
@endverbatim
because TinyXml sees this as a !DOCTYPE node with an illegally
embedded !ELEMENT node. This may be addressed in the future.
<h2> Tutorials. </h2>
For the impatient, here is a tutorial to get you going. A great way to get started,
but it is worth your time to read this (very short) manual completely.
- @subpage tutorial0
<h2> Code Status. </h2>
TinyXml is mature, tested code. It is very stable. If you find
bugs, please file a bug report on the sourceforge web site
(www.sourceforge.net/projects/tinyxml).
We'll get them straightened out as soon as possible.
There are some areas of improvement; please check sourceforge if you are
interested in working on TinyXml.
<h2> Features </h2>
<h3> Using STL </h3>
TinyXml can be compiled to use or not use STL. When using STL, TinyXml
uses the std::string class, and fully supports std::istream, std::ostream,
operator<<, and operator>>. Many API methods have both 'const char*' and
'const std::string&' forms.
When STL support is compiled out, no STL files are included whatsover. All
the string classes are implemented by TinyXml itself. API methods
all use the 'const char*' form for input.
Use the compile time #define:
TIXML_USE_STL
to compile one version or the other. This can be passed by the compiler,
or set as the first line of "tinyxml.h".
Note: If compiling the test code in Linux, setting the environment
variable TINYXML_USE_STL=YES/NO will control STL compilation. In the
Windows project file, STL and non STL targets are provided. In your project,
its probably easiest to add the line "#define TIXML_USE_STL" as the first
line of tinyxml.h.
<h3> UTF-8 </h3>
TinyXml supports UTF-8 allowing to manipulate XML files in any language. TinyXml
also supports "legacy mode" - the encoding used before UTF-8 support and
probably best described as "extended ascii".
Normally, TinyXml will try to detect the correct encoding and use it. However,
by setting the value of TIXML_DEFAULT_ENCODING in the header file, TinyXml
can be forced to always use one encoding.
TinyXml will assume Legacy Mode until one of the following occurs:
<ol>
<li> If the non-standard but common "UTF-8 lead bytes" (0xef 0xbb 0xbf)
begin the file or data stream, TinyXml will read it as UTF-8. </li>
<li> If the declaration tag is read, and it has an encoding="UTF-8", then
TinyXml will read it as UTF-8. </li>
<li> If the declaration tag is read, and it has no encoding specified, then
TinyXml will read it as UTF-8. </li>
<li> If the declaration tag is read, and it has an encoding="something else", then
TinyXml will read it as Legacy Mode. In legacy mode, TinyXml will
work as it did before. It's not clear what that mode does exactly, but
old content should keep working.</li>
<li> Until one of the above criteria is met, TinyXml runs in Legacy Mode.</li>
</ol>
What happens if the encoding is incorrectly set or detected? TinyXml will try
to read and pass through text seen as improperly encoded. You may get some strange
results or mangled characters. You may want to force TinyXml to the correct mode.
<b> You may force TinyXml to Legacy Mode by using LoadFile( TIXML_ENCODING_LEGACY ) or
LoadFile( filename, TIXML_ENCODING_LEGACY ). You may force it to use legacy mode all
the time by setting TIXML_DEFAULT_ENCODING = TIXML_ENCODING_LEGACY. Likewise, you may
force it to TIXML_ENCODING_UTF8 with the same technique.</b>
For English users, using English XML, UTF-8 is the same as low-ASCII. You
don't need to be aware of UTF-8 or change your code in any way. You can think
of UTF-8 as a "superset" of ASCII.
UTF-8 is not a double byte format - but it is a standard encoding of Unicode!
TinyXml does not use or directly support wchar, TCHAR, or Microsofts _UNICODE at this time.
It is common to see the term "Unicode" improperly refer to UTF-16, a wide byte encoding
of unicode. This is a source of confusion.
For "high-ascii" languages - everything not English, pretty much - TinyXml can
handle all languages, at the same time, as long as the XML is encoded
in UTF-8. That can be a little tricky, older programs and operating systems
tend to use the "default" or "traditional" code page. Many apps (and almost all
modern ones) can output UTF-8, but older or stubborn (or just broken) ones
still output text in the default code page.
For example, Japanese systems traditionally use SHIFT-JIS encoding.
Text encoded as SHIFT-JIS can not be read by tinyxml.
A good text editor can import SHIFT-JIS and then save as UTF-8.
The <a href="http://skew.org/xml/tutorial/">Skew.org link</a> does a great
job covering the encoding issue.
The test file "utf8test.xml" is an XML containing English, Spanish, Russian,
and Simplified Chinese. (Hopefully they are translated correctly). The file
"utf8test.gif" is a screen capture of the XML file, rendered in IE. Note that
if you don't have the correct fonts (Simplified Chinese or Russian) on your
system, you won't see output that matches the GIF file even if you can parse
it correctly. Also note that (at least on my Windows machine) console output
is in a Western code page, so that Print() or printf() cannot correctly display
the file. This is not a bug in TinyXml - just an OS issue.
没有合适的资源?快使用搜索试试~ 我知道了~
O语言IDE源代码(类似VC2008界面)
共665个文件
h:206个
cpp:118个
cxx:106个
5星 · 超过95%的资源 需积分: 10 56 下载量 151 浏览量
2009-06-26
19:05:47
上传
评论
收藏 2.66MB RAR 举报
温馨提示
O语言集成开发环境(IDE)源代码,这个源代码主要使用了微软的Feature界面库、scintilla跨平台的语法加亮代码编辑控件、hexeditbase十六进制编辑控件及其它一些控件,并集成了调试功能。详情请看:http://www.olanguage.org/introduction/ide_source/
资源推荐
资源详情
资源评论
收起资源包目录
O语言IDE源代码(类似VC2008界面) (665个子文件)
OLIDE.APS 1.1MB
ScintillaDemo.aps 38KB
ScintillaDemo.aps 35KB
XFolderDialog.aps 33KB
XFolderDialog.rc.bak 3KB
zipsrc.bat 203B
delbin.bat 157B
delcvs.bat 22B
menuimages_hc.bmp 22KB
add new item.bmp 10KB
UserImages.bmp 8KB
Toolbar256.bmp 7KB
复件 Toolbar256.bmp 6KB
bmp00001.bmp 5KB
classview_hc.bmp 5KB
build_co.bmp 4KB
solution.bmp 4KB
menuimages.bmp 4KB
Toolbar_Build.bmp 4KB
toolbar2.bmp 3KB
properties_hc.bmp 3KB
fileview_hc.bmp 2KB
Toolbar.bmp 2KB
sort_hc.bmp 2KB
searchInFiles.bmp 1KB
Toolbar.bmp 1KB
classview.bmp 958B
explorer_hc.bmp 824B
properties.bmp 630B
fileview.bmp 478B
sort.bmp 374B
explorer.bmp 246B
hdrdown.bmp 158B
hdrup.bmp 158B
scintilla-marshal.c 4KB
ListViewCtrlEx.cpp 170KB
ScintillaCtrl.cpp 93KB
ScintillaCtrl.cpp 90KB
hexeditbase.cpp 63KB
MainFrm.cpp 62KB
ScintillaDocView.cpp 58KB
ScintillaDocView.cpp 53KB
OLIDEView.cpp 49KB
utils.cpp 49KB
TreePropSheetBase.cpp 44KB
tinyxmlparser.cpp 34KB
tinyxml.cpp 33KB
xmltest.cpp 32KB
SearchInFilesDock.cpp 30KB
XFolderDialog.cpp 25KB
FileView.cpp 23KB
SolutionTree.cpp 23KB
SystemOption.cpp 23KB
TreePropSheetSplitter.cpp 22KB
ProcessSearchInFiles.cpp 20KB
ODebugger.cpp 18KB
ResizableLayout.cpp 16KB
TreePropSheetEx.cpp 16KB
TreePropSheetResizableLibHook.cpp 15KB
MemWatchWnd.cpp 15KB
CPUWatchWnd.cpp 13KB
NppSearchInFiles.cpp 13KB
HyperLink.cpp 12KB
HexEdit.cpp 12KB
ScintillaDemoView.cpp 12KB
DlgEditOption.cpp 12KB
DlgAddNewItemManager.cpp 12KB
XHistoryCombo.cpp 11KB
OASMBuild.cpp 11KB
OLIDE.cpp 11KB
PropPageFrameEx.cpp 10KB
BuildProject.cpp 10KB
hookwnd.cpp 9KB
Global.cpp 9KB
ClassView.cpp 9KB
main.cpp 9KB
PropertiesWnd.cpp 8KB
OTracer.cpp 8KB
ResizableGrip.cpp 8KB
cgfiltyp.cpp 8KB
OLXMLProjectFile.cpp 7KB
XTreeCtrl.cpp 7KB
OutputWnd.cpp 7KB
AutoCompleteListCtrl.cpp 7KB
XFileOpenListView.cpp 7KB
DlgLinkProperty.cpp 7KB
OLXMLSolutionFile.cpp 7KB
URLCtrl.cpp 7KB
MainFrm.cpp 7KB
TreePropSheetTreeCtrl.cpp 6KB
HintString.cpp 5KB
ReadDebugData.cpp 5KB
PropPageFrameOffice2003.cpp 5KB
AutoCompleteString.cpp 5KB
searchResultsListCtrl.cpp 5KB
StaticDialog.cpp 5KB
FontStatic.cpp 5KB
PeFile.cpp 4KB
GradientStatic.cpp 4KB
PropPageFrame.cpp 4KB
共 665 条
- 1
- 2
- 3
- 4
- 5
- 6
- 7
资源评论
- zhaoxingqi19862014-03-08虽然编译了,但毕可以阅读
- u0111685622013-06-23每次下载一个源码我都不懂如何把它编译出来,我也没编译成功!!
- maze06112012-04-28VS2008 的工程,虽然我的2005编译不了,但是读代码也不错!
linyjg
- 粉丝: 0
- 资源: 3
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功