1 | <HTML><HEAD><SCRIPT language="JavaScript" src="../resources/script.js" type="text/javascript"></SCRIPT><TITLE>XMLUri.hpp Source File</TITLE><link href="XercesApi.css" rel="stylesheet" type="text/css"></HEAD><BODY alink="#ff0000" bgcolor="#ffffff" leftmargin="4" link="#0000ff" marginheight="4" marginwidth="4" text="#000000" topmargin="4" vlink="#0000aa"><TABLE border="0" cellpadding="0" cellspacing="0" width="620"><TR><TD align="left" height="60" rowspan="3" valign="top" width="135"><IMG border="0" height="60" hspace="0" src="../resources/logo.gif" vspace="0" width="135"></TD><TD align="left" colspan="4" height="5" valign="top" width="456"><IMG border="0" height="5" hspace="0" src="../resources/line.gif" vspace="0" width="456"></TD><TD align="left" height="60" rowspan="3" valign="top" width="29"><IMG border="0" height="60" hspace="0" src="../resources/right.gif" vspace="0" width="29"></TD></TR><TR><TD align="left" bgcolor="#0086b2" colspan="4" height="35" valign="top" width="456"><IMG alt="" border="0" height="35" hspace="0" src="../graphics/api-header.jpg" vspace="0" width="456"></TD></TR><TR><TD align="left" height="20" valign="top" width="168"><IMG border="0" height="20" hspace="0" src="../resources/bottom.gif" vspace="0" width="168"></TD><TD align="left" height="20" valign="top" width="96"><A href="http://xml.apache.org/" onMouseOut="rolloverOff('xml');" onMouseOver="rolloverOn('xml');" target="new"><IMG alt="http://xml.apache.org/" border="0" height="20" hspace="0" name="xml" onLoad="rolloverLoad('xml','../resources/button-xml-hi.gif','../resources/button-xml-lo.gif');" src="../resources/button-xml-lo.gif" vspace="0" width="96"></A></TD><TD align="left" height="20" valign="top" width="96"><A href="http://www.apache.org/" onMouseOut="rolloverOff('asf');" onMouseOver="rolloverOn('asf');" target="new"><IMG alt="http://www.apache.org/" border="0" height="20" hspace="0" name="asf" onLoad="rolloverLoad('asf','../resources/button-asf-hi.gif','../resources/button-asf-lo.gif');" src="../resources/button-asf-lo.gif" vspace="0" width="96"></A></TD><TD align="left" height="20" valign="top" width="96"><A href="http://www.w3.org/" onMouseOut="rolloverOff('w3c');" onMouseOver="rolloverOn('w3c');" target="new"><IMG alt="http://www.w3.org/" border="0" height="20" hspace="0" name="w3c" onLoad="rolloverLoad('w3c','../resources/button-w3c-hi.gif','../resources/button-w3c-lo.gif');" src="../resources/button-w3c-lo.gif" vspace="0" width="96"></A></TD></TR></TABLE><TABLE border="0" cellpadding="0" cellspacing="0" width="620"><TR><TD align="left" valign="top" width="120"><IMG border="0" height="14" hspace="0" src="../resources/join.gif" vspace="0" width="120"><BR>
|
---|
2 | <A href="../../index.html" onMouseOut="rolloverOff('side-ext-2');" onMouseOver="rolloverOn('side-ext-2');"><IMG alt="Home" border="0" height="12" hspace="0" name="side-ext-2" onLoad="rolloverLoad('side-ext-2','../graphics/ext-2-label-2.jpg','../graphics/ext-2-label-3.jpg');" src="../graphics/ext-2-label-3.jpg" vspace="0" width="120"></A><BR>
|
---|
3 |
|
---|
4 | <IMG border="0" height="6" hspace="0" src="../resources/separator.gif" vspace="0" width="120"><BR>
|
---|
5 |
|
---|
6 | <A href="../index.html" onMouseOut="rolloverOff('side-index');" onMouseOver="rolloverOn('side-index');"><IMG alt="Readme" border="0" height="12" hspace="0" name="side-index" onLoad="rolloverLoad('side-index','../graphics/index-label-2.jpg','../graphics/index-label-3.jpg');" src="../graphics/index-label-3.jpg" vspace="0" width="120"></A><BR>
|
---|
7 | <A href="../releases.html" onMouseOut="rolloverOff('side-releases');" onMouseOver="rolloverOn('side-releases');"><IMG alt="Release Info" border="0" height="12" hspace="0" name="side-releases" onLoad="rolloverLoad('side-releases','../graphics/releases-label-2.jpg','../graphics/releases-label-3.jpg');" src="../graphics/releases-label-3.jpg" vspace="0" width="120"></A><BR>
|
---|
8 | <IMG border="0" height="6" hspace="0" src="../resources/separator.gif" vspace="0" width="120"><BR>
|
---|
9 | <A href="../install.html" onMouseOut="rolloverOff('side-install');" onMouseOver="rolloverOn('side-install');"><IMG alt="Installation" border="0" height="12" hspace="0" name="side-install" onLoad="rolloverLoad('side-install','../graphics/install-label-2.jpg','../graphics/install-label-3.jpg');" src="../graphics/install-label-3.jpg" vspace="0" width="120"></A><BR>
|
---|
10 | <A href="http://xml.apache.org/dist/xerces-c/" onMouseOut="rolloverOff('side-ext-18');" onMouseOver="rolloverOn('side-ext-18');"><IMG alt="Download" border="0" height="12" hspace="0" name="side-ext-18" onLoad="rolloverLoad('side-ext-18','../graphics/ext-18-label-2.jpg','../graphics/ext-18-label-3.jpg');" src="../graphics/ext-18-label-3.jpg" vspace="0" width="120"></A><BR>
|
---|
11 | <A href="../build.html" onMouseOut="rolloverOff('side-build');" onMouseOver="rolloverOn('side-build');"><IMG alt="Build" border="0" height="12" hspace="0" name="side-build" onLoad="rolloverLoad('side-build','../graphics/build-label-2.jpg','../graphics/build-label-3.jpg');" src="../graphics/build-label-3.jpg" vspace="0" width="120"></A><BR>
|
---|
12 |
|
---|
13 | <IMG border="0" height="6" hspace="0" src="../resources/separator.gif" vspace="0" width="120"><BR>
|
---|
14 | <A href="../faqs.html" onMouseOut="rolloverOff('side-faqs');" onMouseOver="rolloverOn('side-faqs');"><IMG alt="FAQs" border="0" height="12" hspace="0" name="side-faqs" onLoad="rolloverLoad('side-faqs','../graphics/faqs-label-2.jpg','../graphics/faqs-label-3.jpg');" src="../graphics/faqs-label-3.jpg" vspace="0" width="120"></A><BR>
|
---|
15 | <A href="../samples.html" onMouseOut="rolloverOff('side-samples');" onMouseOver="rolloverOn('side-samples');"><IMG alt="Samples" border="0" height="12" hspace="0" name="side-samples" onLoad="rolloverLoad('side-samples','../graphics/samples-label-2.jpg','../graphics/samples-label-3.jpg');" src="../graphics/samples-label-3.jpg" vspace="0" width="120"></A><BR>
|
---|
16 | <A href="../api.html" onMouseOut="rolloverOff('side-api');" onMouseOver="rolloverOn('side-api');"><IMG alt="API Docs" border="0" height="12" hspace="0" name="side-api" onLoad="rolloverLoad('side-api','../graphics/api-label-2.jpg','../graphics/api-label-3.jpg');" src="../graphics/api-label-3.jpg" vspace="0" width="120"></A><BR>
|
---|
17 |
|
---|
18 | <IMG border="0" height="6" hspace="0" src="../resources/separator.gif" vspace="0" width="120"><BR>
|
---|
19 | <A href="../ApacheDOMC++Binding.html" onMouseOut="rolloverOff('side-ext-68');" onMouseOver="rolloverOn('side-ext-68');"><IMG alt="DOM C++ Binding" border="0" height="12" hspace="0" name="side-ext-68" onLoad="rolloverLoad('side-ext-68','../graphics/ext-68-label-2.jpg','../graphics/ext-68-label-3.jpg');" src="../graphics/ext-68-label-3.jpg" vspace="0" width="120"></A><BR>
|
---|
20 |
|
---|
21 | <A href="../program.html" onMouseOut="rolloverOff('side-program');" onMouseOver="rolloverOn('side-program');"><IMG alt="Programming" border="0" height="12" hspace="0" name="side-program" onLoad="rolloverLoad('side-program','../graphics/program-label-2.jpg','../graphics/program-label-3.jpg');" src="../graphics/program-label-3.jpg" vspace="0" width="120"></A><BR>
|
---|
22 | <A href="../migrate.html" onMouseOut="rolloverOff('side-migrate');" onMouseOver="rolloverOn('side-migrate');"><IMG alt="Migration Guide" border="0" height="12" hspace="0" name="side-migrate" onLoad="rolloverLoad('side-migrate','../graphics/migrate-label-2.jpg','../graphics/migrate-label-3.jpg');" src="../graphics/migrate-label-3.jpg" vspace="0" width="120"></A><BR>
|
---|
23 |
|
---|
24 | <IMG border="0" height="6" hspace="0" src="../resources/separator.gif" vspace="0" width="120"><BR>
|
---|
25 |
|
---|
26 | <A href="../feedback.html" onMouseOut="rolloverOff('side-feedback');" onMouseOver="rolloverOn('side-feedback');"><IMG alt="Feedback" border="0" height="12" hspace="0" name="side-feedback" onLoad="rolloverLoad('side-feedback','../graphics/feedback-label-2.jpg','../graphics/feedback-label-3.jpg');" src="../graphics/feedback-label-3.jpg" vspace="0" width="120"></A><BR>
|
---|
27 | <A href="../bug-report.html" onMouseOut="rolloverOff('side-bug-report');" onMouseOver="rolloverOn('side-bug-report');"><IMG alt="Bug-Reporting" border="0" height="12" hspace="0" name="side-bug-report" onLoad="rolloverLoad('side-bug-report','../graphics/bug-report-label-2.jpg','../graphics/bug-report-label-3.jpg');" src="../graphics/bug-report-label-3.jpg" vspace="0" width="120"></A><BR>
|
---|
28 | <A href="../pdf.html" onMouseOut="rolloverOff('side-pdf');" onMouseOver="rolloverOn('side-pdf');"><IMG alt="PDF Document" border="0" height="12" hspace="0" name="side-pdf" onLoad="rolloverLoad('side-pdf','../graphics/pdf-label-2.jpg','../graphics/pdf-label-3.jpg');" src="../graphics/pdf-label-3.jpg" vspace="0" width="120"></A><BR>
|
---|
29 |
|
---|
30 | <IMG border="0" height="6" hspace="0" src="../resources/separator.gif" vspace="0" width="120"><BR>
|
---|
31 |
|
---|
32 | <A href="http://xml.apache.org/websrc/cvsweb.cgi/xml-xerces/c/" onMouseOut="rolloverOff('side-ext-100');" onMouseOver="rolloverOn('side-ext-100');"><IMG alt="CVS Repository" border="0" height="12" hspace="0" name="side-ext-100" onLoad="rolloverLoad('side-ext-100','../graphics/ext-100-label-2.jpg','../graphics/ext-100-label-3.jpg');" src="../graphics/ext-100-label-3.jpg" vspace="0" width="120"></A><BR>
|
---|
33 |
|
---|
34 | <A href="http://marc.theaimsgroup.com/?l=xerces-c-dev" onMouseOut="rolloverOff('side-ext-102');" onMouseOver="rolloverOn('side-ext-102');"><IMG alt="Mail Archive" border="0" height="12" hspace="0" name="side-ext-102" onLoad="rolloverLoad('side-ext-102','../graphics/ext-102-label-2.jpg','../graphics/ext-102-label-3.jpg');" src="../graphics/ext-102-label-3.jpg" vspace="0" width="120"></A><BR>
|
---|
35 |
|
---|
36 |
|
---|
37 | <IMG border="0" height="14" hspace="0" src="../resources/close.gif" vspace="0" width="120"><BR></TD><TD align="left" valign="top" width="500"><TABLE border="0" cellpadding="3" cellspacing="0"><TR><TD>
|
---|
38 | <TABLE border="0" cellpadding="0" cellspacing="0" width="494"><TR><TD bgcolor="#FFFFFF" colspan="2" width="494"><TABLE border="0" cellpadding="0" cellspacing="0" width="494"><TR><TD bgcolor="#039acc" height="1" width="1"><IMG border="0" height="1" hspace="0" src="../resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#039acc" height="1" width="492"><IMG border="0" height="1" hspace="0" src="../resources/void.gif" vspace="0" width="492"></TD><TD bgcolor="#0086b2" height="1" width="1"><IMG border="0" height="1" hspace="0" src="../resources/void.gif" vspace="0" width="1"></TD></TR><TR><TD bgcolor="#039acc" width="1"><IMG border="0" height="1" hspace="0" src="../resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#0086b2" width="492"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="+1"><IMG border="0" height="2" hspace="0" src="../resources/void.gif" vspace="0" width="2"><B>API Docs for SAX and DOM</B></FONT></TD><TD bgcolor="#017299" width="1"><IMG border="0" height="1" hspace="0" src="../resources/void.gif" vspace="0" width="1"></TD></TR><TR><TD bgcolor="#0086b2" height="1" width="1"><IMG border="0" height="1" hspace="0" src="../resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#017299" height="1" width="492"><IMG border="0" height="1" hspace="0" src="../resources/void.gif" vspace="0" width="492"></TD><TD bgcolor="#017299" height="1" width="1"><IMG border="0" height="1" hspace="0" src="../resources/void.gif" vspace="0" width="1"></TD></TR></TABLE></TD></TR><TR><TD width="10"> </TD><TD width="484"><FONT color="#000000" face="arial,helvetica,sanserif">
|
---|
39 |
|
---|
40 | <P>
|
---|
41 | <!-- Generated by Doxygen 1.2.14 -->
|
---|
42 | <center>
|
---|
43 | <a class="qindex" href="index.html">Main Page</a> <a class="qindex" href="hierarchy.html">Class Hierarchy</a> <a class="qindex" href="classes.html">Alphabetical List</a> <a class="qindex" href="annotated.html">Compound List</a> <a class="qindex" href="files.html">File List</a> <a class="qindex" href="functions.html">Compound Members</a> <a class="qindex" href="globals.html">File Members</a> </center>
|
---|
44 | <hr><h1>XMLUri.hpp</h1><a href="XMLUri_8hpp.html">Go to the documentation of this file.</a><div class="fragment"><pre>00001 <font class="comment">/*</font>
|
---|
45 | 00002 <font class="comment"> * Copyright 2001-2004 The Apache Software Foundation.</font>
|
---|
46 | 00003 <font class="comment"> * </font>
|
---|
47 | 00004 <font class="comment"> * Licensed under the Apache License, Version 2.0 (the "License");</font>
|
---|
48 | 00005 <font class="comment"> * you may not use this file except in compliance with the License.</font>
|
---|
49 | 00006 <font class="comment"> * You may obtain a copy of the License at</font>
|
---|
50 | 00007 <font class="comment"> * </font>
|
---|
51 | 00008 <font class="comment"> * http://www.apache.org/licenses/LICENSE-2.0</font>
|
---|
52 | 00009 <font class="comment"> * </font>
|
---|
53 | 00010 <font class="comment"> * Unless required by applicable law or agreed to in writing, software</font>
|
---|
54 | 00011 <font class="comment"> * distributed under the License is distributed on an "AS IS" BASIS,</font>
|
---|
55 | 00012 <font class="comment"> * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.</font>
|
---|
56 | 00013 <font class="comment"> * See the License for the specific language governing permissions and</font>
|
---|
57 | 00014 <font class="comment"> * limitations under the License.</font>
|
---|
58 | 00015 <font class="comment"> */</font>
|
---|
59 | 00016
|
---|
60 | 00017 <font class="comment">/*</font>
|
---|
61 | 00018 <font class="comment"> * $Id: XMLUri.hpp,v 1.18 2004/09/08 13:56:25 peiyongz Exp $</font>
|
---|
62 | 00019 <font class="comment"> * $Log: XMLUri.hpp,v $</font>
|
---|
63 | 00020 <font class="comment"> * Revision 1.18 2004/09/08 13:56:25 peiyongz</font>
|
---|
64 | 00021 <font class="comment"> * Apache License Version 2.0</font>
|
---|
65 | 00022 <font class="comment"> *</font>
|
---|
66 | 00023 <font class="comment"> * Revision 1.17 2004/05/25 18:11:47 peiyongz</font>
|
---|
67 | 00024 <font class="comment"> * normalizeURI() added</font>
|
---|
68 | 00025 <font class="comment"> *</font>
|
---|
69 | 00026 <font class="comment"> * Revision 1.16 2004/01/12 22:01:02 cargilld</font>
|
---|
70 | 00027 <font class="comment"> * Minor performance change for handling reserved and unreserved characters.</font>
|
---|
71 | 00028 <font class="comment"> *</font>
|
---|
72 | 00029 <font class="comment"> * Revision 1.15 2003/12/17 00:18:35 cargilld</font>
|
---|
73 | 00030 <font class="comment"> * Update to memory management so that the static memory manager (one used to call Initialize) is only for static data.</font>
|
---|
74 | 00031 <font class="comment"> *</font>
|
---|
75 | 00032 <font class="comment"> * Revision 1.14 2003/12/11 22:21:25 neilg</font>
|
---|
76 | 00033 <font class="comment"> * fixes for the URI implementation to take registry names into account; much thanks to Michael Glavassevich</font>
|
---|
77 | 00034 <font class="comment"> *</font>
|
---|
78 | 00035 <font class="comment"> * Revision 1.13 2003/12/02 17:50:21 neilg</font>
|
---|
79 | 00036 <font class="comment"> * additional fix for bug 25118; once again, thanks to Jeroen Whitmond</font>
|
---|
80 | 00037 <font class="comment"> *</font>
|
---|
81 | 00038 <font class="comment"> * Revision 1.12 2003/10/01 00:20:41 knoaman</font>
|
---|
82 | 00039 <font class="comment"> * Add a static method to check whether a given string is a valid URI.</font>
|
---|
83 | 00040 <font class="comment"> *</font>
|
---|
84 | 00041 <font class="comment"> * Revision 1.11 2003/09/25 22:23:25 peiyongz</font>
|
---|
85 | 00042 <font class="comment"> * Implementation of Serialization/Deserialization</font>
|
---|
86 | 00043 <font class="comment"> *</font>
|
---|
87 | 00044 <font class="comment"> * Revision 1.10 2003/07/25 10:15:16 gareth</font>
|
---|
88 | 00045 <font class="comment"> * Patch by Michael Glavassevich</font>
|
---|
89 | 00046 <font class="comment"> *</font>
|
---|
90 | 00047 <font class="comment"> * The patch fixes Bugzilla #19787, #20006, #20009, #20010 and #20287, and</font>
|
---|
91 | 00048 <font class="comment"> * several other issues. A summary of the changes is listed below:</font>
|
---|
92 | 00049 <font class="comment"> *</font>
|
---|
93 | 00050 <font class="comment"> * 1. Added '[' and ']' to reserved characters as per RFC 2732.</font>
|
---|
94 | 00051 <font class="comment"> * 2. '[' and ']' added in RFC 2732, are not allowed in path segments, but</font>
|
---|
95 | 00052 <font class="comment"> * may appear in the opaque part.</font>
|
---|
96 | 00053 <font class="comment"> * 3. No URI can begin with a ':'.</font>
|
---|
97 | 00054 <font class="comment"> * 4. URI has no scheme if ':' occurs in a URI after '?' or '#', it's part of</font>
|
---|
98 | 00055 <font class="comment"> * the query string or fragment.</font>
|
---|
99 | 00056 <font class="comment"> * 5. Whitespace (even escaped as %20) is not permitted in the authority</font>
|
---|
100 | 00057 <font class="comment"> * portion of a URI.</font>
|
---|
101 | 00058 <font class="comment"> * 6. IPv4 addresses must match 1*3DIGIT "." 1*3DIGIT "." 1*3DIGIT "."</font>
|
---|
102 | 00059 <font class="comment"> * 1*3DIGIT. Since RFC 2732.</font>
|
---|
103 | 00060 <font class="comment"> * 7. IPv4 addresses are 32-bit, therefore no segment may be larger than 255.</font>
|
---|
104 | 00061 <font class="comment"> * This isn't expressed by the grammar.</font>
|
---|
105 | 00062 <font class="comment"> * 8. Hostnames cannot end with a '-'.</font>
|
---|
106 | 00063 <font class="comment"> * 9. Labels in a hostname must be 63 bytes or less [RFC 1034].</font>
|
---|
107 | 00064 <font class="comment"> * 10. Hostnames may be no longer than 255 bytes [RFC 1034]. (That</font>
|
---|
108 | 00065 <font class="comment"> * restriction was already there. I just moved it inwards.</font>
|
---|
109 | 00066 <font class="comment"> * 11. Added support for IPv6 references added in RFC 2732. URIs such as</font>
|
---|
110 | 00067 <font class="comment"> * http://[::ffff:1.2.3.4] are valid. The BNF in RFC 2373 isn't correct. IPv6</font>
|
---|
111 | 00068 <font class="comment"> * addresses are read according to section 2.2 of RFC 2373.</font>
|
---|
112 | 00069 <font class="comment"> *</font>
|
---|
113 | 00070 <font class="comment"> * Revision 1.9 2003/05/16 06:01:53 knoaman</font>
|
---|
114 | 00071 <font class="comment"> * Partial implementation of the configurable memory manager.</font>
|
---|
115 | 00072 <font class="comment"> *</font>
|
---|
116 | 00073 <font class="comment"> * Revision 1.8 2003/05/15 19:07:46 knoaman</font>
|
---|
117 | 00074 <font class="comment"> * Partial implementation of the configurable memory manager.</font>
|
---|
118 | 00075 <font class="comment"> *</font>
|
---|
119 | 00076 <font class="comment"> * Revision 1.7 2003/01/06 19:43:18 tng</font>
|
---|
120 | 00077 <font class="comment"> * New feature StandardUriConformant to force strict standard uri conformance.</font>
|
---|
121 | 00078 <font class="comment"> *</font>
|
---|
122 | 00079 <font class="comment"> * Revision 1.6 2002/11/21 15:42:39 gareth</font>
|
---|
123 | 00080 <font class="comment"> * Implemented copy constructor and operator =. Patch by Jennifer Schachter.</font>
|
---|
124 | 00081 <font class="comment"> *</font>
|
---|
125 | 00082 <font class="comment"> * Revision 1.5 2002/11/04 15:22:05 tng</font>
|
---|
126 | 00083 <font class="comment"> * C++ Namespace Support.</font>
|
---|
127 | 00084 <font class="comment"> *</font>
|
---|
128 | 00085 <font class="comment"> * Revision 1.4 2002/09/23 18:41:00 tng</font>
|
---|
129 | 00086 <font class="comment"> * DOM L3: Support baseURI. Add fURIText to XMLUri. Added by Gareth Reakes and Thomas Ford.</font>
|
---|
130 | 00087 <font class="comment"> *</font>
|
---|
131 | 00088 <font class="comment"> * Revision 1.3 2002/08/23 20:45:24 tng</font>
|
---|
132 | 00089 <font class="comment"> * .Memory leak fix: XMLUri data not deleted if constructor failed.</font>
|
---|
133 | 00090 <font class="comment"> *</font>
|
---|
134 | 00091 <font class="comment"> * Revision 1.2 2002/02/20 18:17:02 tng</font>
|
---|
135 | 00092 <font class="comment"> * [Bug 5977] Warnings on generating apiDocs.</font>
|
---|
136 | 00093 <font class="comment"> *</font>
|
---|
137 | 00094 <font class="comment"> * Revision 1.1.1.1 2002/02/01 22:22:17 peiyongz</font>
|
---|
138 | 00095 <font class="comment"> * sane_include</font>
|
---|
139 | 00096 <font class="comment"> *</font>
|
---|
140 | 00097 <font class="comment"> * Revision 1.3 2001/08/29 19:03:03 peiyongz</font>
|
---|
141 | 00098 <font class="comment"> * Bugzilla# 2816:on AIX 4.2, xlC 3 r ev.1, Compilation error on inline method</font>
|
---|
142 | 00099 <font class="comment"> *</font>
|
---|
143 | 00100 <font class="comment"> * Revision 1.2 2001/08/16 14:09:44 peiyongz</font>
|
---|
144 | 00101 <font class="comment"> * Removed unused ctors and methods</font>
|
---|
145 | 00102 <font class="comment"> *</font>
|
---|
146 | 00103 <font class="comment"> * Revision 1.1 2001/08/10 16:23:41 peiyongz</font>
|
---|
147 | 00104 <font class="comment"> * XMLUri: creation</font>
|
---|
148 | 00105 <font class="comment"> *</font>
|
---|
149 | 00106 <font class="comment"> *</font>
|
---|
150 | 00107 <font class="comment"> */</font>
|
---|
151 | 00108
|
---|
152 | 00109 <font class="preprocessor">#if !defined(XMLURI_HPP)</font>
|
---|
153 | <a name="l00110"></a><a class="code" href="XMLUri_8hpp.html#a0">00110</a> <font class="preprocessor"></font><font class="preprocessor">#define XMLURI_HPP</font>
|
---|
154 | 00111 <font class="preprocessor"></font>
|
---|
155 | 00112 <font class="preprocessor">#include <<a class="code" href="XMemory_8hpp.html">xercesc/util/XMemory.hpp</a>></font>
|
---|
156 | 00113 <font class="preprocessor">#include <<a class="code" href="XMLString_8hpp.html">xercesc/util/XMLString.hpp</a>></font>
|
---|
157 | 00114
|
---|
158 | 00115 <font class="preprocessor">#include <xercesc/internal/XSerializable.hpp></font>
|
---|
159 | 00116 <font class="preprocessor">#include <xercesc/framework/XMLBuffer.hpp></font>
|
---|
160 | 00117
|
---|
161 | 00118 <a class="code" href="XercesDefs_8hpp.html#a2">XERCES_CPP_NAMESPACE_BEGIN</a>
|
---|
162 | 00119
|
---|
163 | 00120 <font class="comment">/*</font>
|
---|
164 | 00121 <font class="comment"> * This class is a direct port of Java's URI class, to distinguish</font>
|
---|
165 | 00122 <font class="comment"> * itself from the XMLURL, we use the name XMLUri instead of</font>
|
---|
166 | 00123 <font class="comment"> * XMLURI.</font>
|
---|
167 | 00124 <font class="comment"> *</font>
|
---|
168 | 00125 <font class="comment"> * TODO: how to relate XMLUri and XMLURL since URL is part of URI.</font>
|
---|
169 | 00126 <font class="comment"> *</font>
|
---|
170 | 00127 <font class="comment"> */</font>
|
---|
171 | 00128
|
---|
172 | <a name="l00129"></a><a class="code" href="classXMLUri.html">00129</a> <font class="keyword">class </font><a class="code" href="XercesDefs_8hpp.html#a8"></a> <a class="code" href="classXMLUri.html">XMLUri</a> : <font class="keyword">public</font> XSerializable, <font class="keyword">public</font> <a class="code" href="classXMemory.html">XMemory</a>
|
---|
173 | 00130 {
|
---|
174 | 00131 <font class="keyword">public</font>:
|
---|
175 | 00132
|
---|
176 | 00133 <font class="comment">// -----------------------------------------------------------------------</font>
|
---|
177 | 00134 <font class="comment">// Constructors and Destructor</font>
|
---|
178 | 00135 <font class="comment">// -----------------------------------------------------------------------</font>
|
---|
179 | 00136
|
---|
180 | 00165 <a class="code" href="classXMLUri.html">XMLUri</a>(<font class="keyword">const</font> XMLCh* <font class="keyword">const</font> uriSpec,
|
---|
181 | 00166 <a class="code" href="classMemoryManager.html">MemoryManager</a>* <font class="keyword">const</font> manager = <a class="code" href="classXMLPlatformUtils.html#z488_4">XMLPlatformUtils::fgMemoryManager</a>);
|
---|
182 | 00167
|
---|
183 | 00184 <a class="code" href="classXMLUri.html">XMLUri</a>(<font class="keyword">const</font> <a class="code" href="classXMLUri.html">XMLUri</a>* <font class="keyword">const</font> baseURI
|
---|
184 | 00185 , <font class="keyword">const</font> XMLCh* <font class="keyword">const</font> uriSpec
|
---|
185 | 00186 , <a class="code" href="classMemoryManager.html">MemoryManager</a>* <font class="keyword">const</font> manager = <a class="code" href="classXMLPlatformUtils.html#z488_4">XMLPlatformUtils::fgMemoryManager</a>);
|
---|
186 | 00187
|
---|
187 | 00191 <a class="code" href="classXMLUri.html">XMLUri</a>(<font class="keyword">const</font> <a class="code" href="classXMLUri.html">XMLUri</a>& toCopy);
|
---|
188 | 00192 <a class="code" href="classXMLUri.html">XMLUri</a>& operator=(<font class="keyword">const</font> <a class="code" href="classXMLUri.html">XMLUri</a>& toAssign);
|
---|
189 | 00193
|
---|
190 | 00194 <font class="keyword">virtual</font> ~<a class="code" href="classXMLUri.html">XMLUri</a>();
|
---|
191 | 00195
|
---|
192 | 00196 <font class="comment">// -----------------------------------------------------------------------</font>
|
---|
193 | 00197 <font class="comment">// Getter methods</font>
|
---|
194 | 00198 <font class="comment">// -----------------------------------------------------------------------</font>
|
---|
195 | 00204 <font class="comment"></font> <font class="keyword">const</font> XMLCh* getUriText() <font class="keyword">const</font>;
|
---|
196 | 00205
|
---|
197 | 00211 <font class="keyword">const</font> XMLCh* getScheme() <font class="keyword">const</font>;
|
---|
198 | 00212
|
---|
199 | 00218 <font class="keyword">const</font> XMLCh* getUserInfo() <font class="keyword">const</font>;
|
---|
200 | 00219
|
---|
201 | 00220
|
---|
202 | 00226 <font class="keyword">const</font> XMLCh* getHost() <font class="keyword">const</font>;
|
---|
203 | 00227
|
---|
204 | 00233 <font class="keywordtype">int</font> getPort() <font class="keyword">const</font>;
|
---|
205 | 00234
|
---|
206 | 00240 <font class="keyword">const</font> XMLCh* getRegBasedAuthority() <font class="keyword">const</font>;
|
---|
207 | 00241
|
---|
208 | 00248 <font class="keyword">const</font> XMLCh* getPath() <font class="keyword">const</font>;
|
---|
209 | 00249
|
---|
210 | 00257 <font class="keyword">const</font> XMLCh* getQueryString() <font class="keyword">const</font>;
|
---|
211 | 00258
|
---|
212 | 00266 <font class="keyword">const</font> XMLCh* getFragment() <font class="keyword">const</font>;
|
---|
213 | 00267
|
---|
214 | 00268 <font class="comment">// -----------------------------------------------------------------------</font>
|
---|
215 | 00269 <font class="comment">// Setter methods</font>
|
---|
216 | 00270 <font class="comment">// -----------------------------------------------------------------------</font>
|
---|
217 | 00271
|
---|
218 | 00279 <font class="keywordtype">void</font> setScheme(<font class="keyword">const</font> XMLCh* <font class="keyword">const</font> newScheme);
|
---|
219 | 00280
|
---|
220 | 00288 <font class="keywordtype">void</font> setUserInfo(<font class="keyword">const</font> XMLCh* <font class="keyword">const</font> newUserInfo);
|
---|
221 | 00289
|
---|
222 | 00300 <font class="keywordtype">void</font> setHost(<font class="keyword">const</font> XMLCh* <font class="keyword">const</font> newHost);
|
---|
223 | 00301
|
---|
224 | 00311 <font class="keywordtype">void</font> setPort(<font class="keywordtype">int</font> newPort);
|
---|
225 | 00312
|
---|
226 | 00321 <font class="keywordtype">void</font> setRegBasedAuthority(<font class="keyword">const</font> XMLCh* <font class="keyword">const</font> newRegAuth);
|
---|
227 | 00322
|
---|
228 | 00343 <font class="keywordtype">void</font> setPath(<font class="keyword">const</font> XMLCh* <font class="keyword">const</font> newPath);
|
---|
229 | 00344
|
---|
230 | 00353 <font class="keywordtype">void</font> setQueryString(<font class="keyword">const</font> XMLCh* <font class="keyword">const</font> newQueryString);
|
---|
231 | 00354
|
---|
232 | 00363 <font class="keywordtype">void</font> setFragment(<font class="keyword">const</font> XMLCh* <font class="keyword">const</font> newFragment);
|
---|
233 | 00364
|
---|
234 | 00365 <font class="comment">// -----------------------------------------------------------------------</font>
|
---|
235 | 00366 <font class="comment">// Miscellaneous methods</font>
|
---|
236 | 00367 <font class="comment">// -----------------------------------------------------------------------</font>
|
---|
237 | 00368
|
---|
238 | 00376 <font class="keyword">static</font> <font class="keywordtype">bool</font> isURIString(<font class="keyword">const</font> XMLCh* <font class="keyword">const</font> uric);
|
---|
239 | 00377
|
---|
240 | 00381 <font class="keyword">static</font> <font class="keywordtype">bool</font> isValidURI( <font class="keyword">const</font> <a class="code" href="classXMLUri.html">XMLUri</a>* <font class="keyword">const</font> baseURI
|
---|
241 | 00382 , <font class="keyword">const</font> XMLCh* <font class="keyword">const</font> uriStr);
|
---|
242 | 00386 <font class="keyword">static</font> <font class="keywordtype">bool</font> isValidURI( <font class="keywordtype">bool</font> haveBaseURI
|
---|
243 | 00387 , <font class="keyword">const</font> XMLCh* <font class="keyword">const</font> uriStr);
|
---|
244 | 00388
|
---|
245 | 00389
|
---|
246 | 00390 <font class="keyword">static</font> <font class="keywordtype">void</font> normalizeURI(<font class="keyword">const</font> XMLCh* <font class="keyword">const</font> systemURI,
|
---|
247 | 00391 XMLBuffer& normalizedURI);
|
---|
248 | 00392
|
---|
249 | 00393 <font class="comment">/***</font>
|
---|
250 | 00394 <font class="comment"> * Support for Serialization/De-serialization</font>
|
---|
251 | 00395 <font class="comment"> ***/</font>
|
---|
252 | 00396 DECL_XSERIALIZABLE(<a class="code" href="classXMLUri.html">XMLUri</a>)
|
---|
253 | 00397
|
---|
254 | 00398 <a class="code" href="classXMLUri.html">XMLUri</a>(<a class="code" href="classMemoryManager.html">MemoryManager</a>* <font class="keyword">const</font> manager = <a class="code" href="classXMLPlatformUtils.html#z488_4">XMLPlatformUtils::fgMemoryManager</a>);
|
---|
255 | 00399
|
---|
256 | 00400 <font class="keyword">private</font>:
|
---|
257 | 00401
|
---|
258 | 00402 <font class="keyword">static</font> <font class="keyword">const</font> XMLCh MARK_OR_RESERVED_CHARACTERS[];
|
---|
259 | 00403 <font class="keyword">static</font> <font class="keyword">const</font> XMLCh RESERVED_CHARACTERS[];
|
---|
260 | 00404 <font class="keyword">static</font> <font class="keyword">const</font> XMLCh MARK_CHARACTERS[];
|
---|
261 | 00405 <font class="keyword">static</font> <font class="keyword">const</font> XMLCh SCHEME_CHARACTERS[];
|
---|
262 | 00406 <font class="keyword">static</font> <font class="keyword">const</font> XMLCh USERINFO_CHARACTERS[];
|
---|
263 | 00407 <font class="keyword">static</font> <font class="keyword">const</font> XMLCh REG_NAME_CHARACTERS[];
|
---|
264 | 00408 <font class="keyword">static</font> <font class="keyword">const</font> XMLCh PATH_CHARACTERS[];
|
---|
265 | 00409
|
---|
266 | 00410 <font class="comment">//helper method for getUriText</font>
|
---|
267 | 00411 <font class="keywordtype">void</font> buildFullText();
|
---|
268 | 00412
|
---|
269 | 00413 <font class="comment">// -----------------------------------------------------------------------</font>
|
---|
270 | 00414 <font class="comment">// Private helper methods</font>
|
---|
271 | 00415 <font class="comment">// -----------------------------------------------------------------------</font>
|
---|
272 | 00416
|
---|
273 | 00422 <font class="keyword">static</font> <font class="keywordtype">bool</font> isReservedCharacter(<font class="keyword">const</font> XMLCh theChar);
|
---|
274 | 00423
|
---|
275 | 00429 <font class="keyword">static</font> <font class="keywordtype">bool</font> isPathCharacter(<font class="keyword">const</font> XMLCh theChar);
|
---|
276 | 00430
|
---|
277 | 00436 <font class="keyword">static</font> <font class="keywordtype">bool</font> isUnreservedCharacter(<font class="keyword">const</font> XMLCh theChar);
|
---|
278 | 00437
|
---|
279 | 00443 <font class="keyword">static</font> <font class="keywordtype">bool</font> isReservedOrUnreservedCharacter(<font class="keyword">const</font> XMLCh theChar);
|
---|
280 | 00444
|
---|
281 | 00452 <font class="keyword">static</font> <font class="keywordtype">bool</font> isConformantSchemeName(<font class="keyword">const</font> XMLCh* <font class="keyword">const</font> scheme);
|
---|
282 | 00453
|
---|
283 | 00459 <font class="keyword">static</font> <font class="keywordtype">void</font> isConformantUserInfo(<font class="keyword">const</font> XMLCh* <font class="keyword">const</font> userInfo
|
---|
284 | 00460 , <a class="code" href="classMemoryManager.html">MemoryManager</a>* <font class="keyword">const</font> manager);
|
---|
285 | 00461
|
---|
286 | 00469 <font class="keyword">static</font> <font class="keywordtype">bool</font> isValidServerBasedAuthority(<font class="keyword">const</font> XMLCh* <font class="keyword">const</font> host
|
---|
287 | 00470 , <font class="keyword">const</font> <font class="keywordtype">int</font> hostLen
|
---|
288 | 00471 , <font class="keyword">const</font> <font class="keywordtype">int</font> port
|
---|
289 | 00472 , <font class="keyword">const</font> XMLCh* <font class="keyword">const</font> userinfo
|
---|
290 | 00473 , <font class="keyword">const</font> <font class="keywordtype">int</font> userLen);
|
---|
291 | 00474
|
---|
292 | 00482 <font class="keyword">static</font> <font class="keywordtype">bool</font> isValidServerBasedAuthority(<font class="keyword">const</font> XMLCh* <font class="keyword">const</font> host
|
---|
293 | 00483 , <font class="keyword">const</font> <font class="keywordtype">int</font> port
|
---|
294 | 00484 , <font class="keyword">const</font> XMLCh* <font class="keyword">const</font> userinfo
|
---|
295 | 00485 , <a class="code" href="classMemoryManager.html">MemoryManager</a>* <font class="keyword">const</font> manager);
|
---|
296 | 00486
|
---|
297 | 00494 <font class="keyword">static</font> <font class="keywordtype">bool</font> isValidRegistryBasedAuthority(<font class="keyword">const</font> XMLCh* <font class="keyword">const</font> authority
|
---|
298 | 00495 , <font class="keyword">const</font> <font class="keywordtype">int</font> authLen);
|
---|
299 | 00496
|
---|
300 | 00504 <font class="keyword">static</font> <font class="keywordtype">bool</font> isValidRegistryBasedAuthority(<font class="keyword">const</font> XMLCh* <font class="keyword">const</font> authority);
|
---|
301 | 00505
|
---|
302 | 00523 <font class="keyword">static</font> <font class="keywordtype">bool</font> isWellFormedAddress(<font class="keyword">const</font> XMLCh* <font class="keyword">const</font> addr
|
---|
303 | 00524 , <a class="code" href="classMemoryManager.html">MemoryManager</a>* <font class="keyword">const</font> manager);
|
---|
304 | 00525
|
---|
305 | 00535 <font class="keyword">static</font> <font class="keywordtype">bool</font> isWellFormedIPv4Address(<font class="keyword">const</font> XMLCh* <font class="keyword">const</font> addr, <font class="keyword">const</font> <font class="keywordtype">int</font> length);
|
---|
306 | 00536
|
---|
307 | 00550 <font class="keyword">static</font> <font class="keywordtype">bool</font> isWellFormedIPv6Reference(<font class="keyword">const</font> XMLCh* <font class="keyword">const</font> addr, <font class="keyword">const</font> <font class="keywordtype">int</font> length);
|
---|
308 | 00551
|
---|
309 | 00567 <font class="keyword">static</font> <font class="keywordtype">int</font> scanHexSequence (<font class="keyword">const</font> XMLCh* <font class="keyword">const</font> addr, <font class="keywordtype">int</font> index, <font class="keywordtype">int</font> end, <font class="keywordtype">int</font>& counter);
|
---|
310 | 00568
|
---|
311 | 00576 <font class="keywordtype">bool</font> isGenericURI();
|
---|
312 | 00577
|
---|
313 | 00578 <font class="comment">// -----------------------------------------------------------------------</font>
|
---|
314 | 00579 <font class="comment">// Miscellaneous methods</font>
|
---|
315 | 00580 <font class="comment">// -----------------------------------------------------------------------</font>
|
---|
316 | 00581
|
---|
317 | 00587 <font class="keywordtype">void</font> initialize(<font class="keyword">const</font> <a class="code" href="classXMLUri.html">XMLUri</a>& toCopy);
|
---|
318 | 00588
|
---|
319 | 00603 <font class="keywordtype">void</font> initialize(<font class="keyword">const</font> <a class="code" href="classXMLUri.html">XMLUri</a>* <font class="keyword">const</font> baseURI
|
---|
320 | 00604 , <font class="keyword">const</font> XMLCh* <font class="keyword">const</font> uriSpec);
|
---|
321 | 00605
|
---|
322 | 00612 <font class="keywordtype">void</font> initializeScheme(<font class="keyword">const</font> XMLCh* <font class="keyword">const</font> uriSpec);
|
---|
323 | 00613
|
---|
324 | 00621 <font class="keywordtype">void</font> initializeAuthority(<font class="keyword">const</font> XMLCh* <font class="keyword">const</font> uriSpec);
|
---|
325 | 00622
|
---|
326 | 00629 <font class="keywordtype">void</font> initializePath(<font class="keyword">const</font> XMLCh* <font class="keyword">const</font> uriSpec);
|
---|
327 | 00630
|
---|
328 | 00635 <font class="keywordtype">void</font> cleanUp();
|
---|
329 | 00636
|
---|
330 | 00637 <font class="keyword">static</font> <font class="keywordtype">bool</font> isConformantSchemeName(<font class="keyword">const</font> XMLCh* <font class="keyword">const</font> scheme,
|
---|
331 | 00638 <font class="keyword">const</font> <font class="keywordtype">int</font> schemeLen);
|
---|
332 | 00639 <font class="keyword">static</font> <font class="keywordtype">bool</font> processScheme(<font class="keyword">const</font> XMLCh* <font class="keyword">const</font> uriStr, <font class="keywordtype">int</font>& index);
|
---|
333 | 00640 <font class="keyword">static</font> <font class="keywordtype">bool</font> processAuthority(<font class="keyword">const</font> XMLCh* <font class="keyword">const</font> uriStr, <font class="keyword">const</font> <font class="keywordtype">int</font> authLen);
|
---|
334 | 00641 <font class="keyword">static</font> <font class="keywordtype">bool</font> isWellFormedAddress(<font class="keyword">const</font> XMLCh* <font class="keyword">const</font> addr, <font class="keyword">const</font> <font class="keywordtype">int</font> addrLen);
|
---|
335 | 00642 <font class="keyword">static</font> <font class="keywordtype">bool</font> processPath(<font class="keyword">const</font> XMLCh* <font class="keyword">const</font> pathStr, <font class="keyword">const</font> <font class="keywordtype">int</font> pathStrLen,
|
---|
336 | 00643 <font class="keyword">const</font> <font class="keywordtype">bool</font> isSchemePresent);
|
---|
337 | 00644
|
---|
338 | 00645 <font class="comment">// -----------------------------------------------------------------------</font>
|
---|
339 | 00646 <font class="comment">// Data members</font>
|
---|
340 | 00647 <font class="comment">//</font>
|
---|
341 | 00648 <font class="comment">// for all the data member, we own it,</font>
|
---|
342 | 00649 <font class="comment">// responsible for the creation and/or deletion for</font>
|
---|
343 | 00650 <font class="comment">// the memory allocated.</font>
|
---|
344 | 00651 <font class="comment">//</font>
|
---|
345 | 00652 <font class="comment">// -----------------------------------------------------------------------</font>
|
---|
346 | 00653 XMLCh* fScheme;
|
---|
347 | 00654 XMLCh* fUserInfo;
|
---|
348 | 00655 XMLCh* fHost;
|
---|
349 | 00656 <font class="keywordtype">int</font> fPort;
|
---|
350 | 00657 XMLCh* fRegAuth;
|
---|
351 | 00658 XMLCh* fPath;
|
---|
352 | 00659 XMLCh* fQueryString;
|
---|
353 | 00660 XMLCh* fFragment;
|
---|
354 | 00661 XMLCh* fURIText;
|
---|
355 | 00662 <a class="code" href="classMemoryManager.html">MemoryManager</a>* fMemoryManager;
|
---|
356 | 00663 };
|
---|
357 | 00664
|
---|
358 | 00665 <font class="comment">// ---------------------------------------------------------------------------</font>
|
---|
359 | 00666 <font class="comment">// XMLUri: Getter methods</font>
|
---|
360 | 00667 <font class="comment">// ---------------------------------------------------------------------------</font>
|
---|
361 | <a name="l00668"></a><a class="code" href="classXMLUri.html#a6">00668</a> <font class="keyword">inline</font> <font class="keyword">const</font> XMLCh* <a class="code" href="classXMLUri.html#a6">XMLUri::getScheme</a>()<font class="keyword"> const</font>
|
---|
362 | 00669 <font class="keyword"></font>{
|
---|
363 | 00670 <font class="keywordflow">return</font> fScheme;
|
---|
364 | 00671 }
|
---|
365 | 00672
|
---|
366 | <a name="l00673"></a><a class="code" href="classXMLUri.html#a7">00673</a> <font class="keyword">inline</font> <font class="keyword">const</font> XMLCh* <a class="code" href="classXMLUri.html#a7">XMLUri::getUserInfo</a>()<font class="keyword"> const</font>
|
---|
367 | 00674 <font class="keyword"></font>{
|
---|
368 | 00675 <font class="keywordflow">return</font> fUserInfo;
|
---|
369 | 00676 }
|
---|
370 | 00677
|
---|
371 | <a name="l00678"></a><a class="code" href="classXMLUri.html#a8">00678</a> <font class="keyword">inline</font> <font class="keyword">const</font> XMLCh* <a class="code" href="classXMLUri.html#a8">XMLUri::getHost</a>()<font class="keyword"> const</font>
|
---|
372 | 00679 <font class="keyword"></font>{
|
---|
373 | 00680 <font class="keywordflow">return</font> fHost;
|
---|
374 | 00681 }
|
---|
375 | 00682
|
---|
376 | <a name="l00683"></a><a class="code" href="classXMLUri.html#a9">00683</a> <font class="keyword">inline</font> <font class="keywordtype">int</font> <a class="code" href="classXMLUri.html#a9">XMLUri::getPort</a>()<font class="keyword"> const</font>
|
---|
377 | 00684 <font class="keyword"></font>{
|
---|
378 | 00685 <font class="keywordflow">return</font> fPort;
|
---|
379 | 00686 }
|
---|
380 | 00687
|
---|
381 | <a name="l00688"></a><a class="code" href="classXMLUri.html#a10">00688</a> <font class="keyword">inline</font> <font class="keyword">const</font> XMLCh* <a class="code" href="classXMLUri.html#a10">XMLUri::getRegBasedAuthority</a>()<font class="keyword"> const</font>
|
---|
382 | 00689 <font class="keyword"></font>{
|
---|
383 | 00690 <font class="keywordflow">return</font> fRegAuth;
|
---|
384 | 00691 }
|
---|
385 | 00692
|
---|
386 | <a name="l00693"></a><a class="code" href="classXMLUri.html#a11">00693</a> <font class="keyword">inline</font> <font class="keyword">const</font> XMLCh* <a class="code" href="classXMLUri.html#a11">XMLUri::getPath</a>()<font class="keyword"> const</font>
|
---|
387 | 00694 <font class="keyword"></font>{
|
---|
388 | 00695 <font class="keywordflow">return</font> fPath;
|
---|
389 | 00696 }
|
---|
390 | 00697
|
---|
391 | <a name="l00698"></a><a class="code" href="classXMLUri.html#a12">00698</a> <font class="keyword">inline</font> <font class="keyword">const</font> XMLCh* <a class="code" href="classXMLUri.html#a12">XMLUri::getQueryString</a>()<font class="keyword"> const</font>
|
---|
392 | 00699 <font class="keyword"></font>{
|
---|
393 | 00700 <font class="keywordflow">return</font> fQueryString;
|
---|
394 | 00701 }
|
---|
395 | 00702
|
---|
396 | <a name="l00703"></a><a class="code" href="classXMLUri.html#a13">00703</a> <font class="keyword">inline</font> <font class="keyword">const</font> XMLCh* <a class="code" href="classXMLUri.html#a13">XMLUri::getFragment</a>()<font class="keyword"> const</font>
|
---|
397 | 00704 <font class="keyword"></font>{
|
---|
398 | 00705 <font class="keywordflow">return</font> fFragment;
|
---|
399 | 00706 }
|
---|
400 | 00707
|
---|
401 | <a name="l00708"></a><a class="code" href="classXMLUri.html#a5">00708</a> <font class="keyword">inline</font> <font class="keyword">const</font> XMLCh* <a class="code" href="classXMLUri.html#a5">XMLUri::getUriText</a>()<font class="keyword"> const</font>
|
---|
402 | 00709 <font class="keyword"></font>{
|
---|
403 | 00710 <font class="comment">//</font>
|
---|
404 | 00711 <font class="comment">// Fault it in if not already. Since this is a const method and we</font>
|
---|
405 | 00712 <font class="comment">// can't use mutable members due the compilers we have to support,</font>
|
---|
406 | 00713 <font class="comment">// we have to cast off the constness.</font>
|
---|
407 | 00714 <font class="comment">//</font>
|
---|
408 | 00715 <font class="keywordflow">if</font> (!fURIText)
|
---|
409 | 00716 ((<a class="code" href="classXMLUri.html">XMLUri</a>*)<font class="keyword">this</font>)->buildFullText();
|
---|
410 | 00717
|
---|
411 | 00718 <font class="keywordflow">return</font> fURIText;
|
---|
412 | 00719 }
|
---|
413 | 00720
|
---|
414 | 00721 <font class="comment">// ---------------------------------------------------------------------------</font>
|
---|
415 | 00722 <font class="comment">// XMLUri: Helper methods</font>
|
---|
416 | 00723 <font class="comment">// ---------------------------------------------------------------------------</font>
|
---|
417 | 00724 <font class="keyword">inline</font> <font class="keywordtype">bool</font> XMLUri::isReservedOrUnreservedCharacter(<font class="keyword">const</font> XMLCh theChar)
|
---|
418 | 00725 {
|
---|
419 | 00726 <font class="keywordflow">return</font> (<a class="code" href="classXMLString.html#z519_17">XMLString::isAlphaNum</a>(theChar) ||
|
---|
420 | 00727 <a class="code" href="classXMLString.html#z515_0">XMLString::indexOf</a>(MARK_OR_RESERVED_CHARACTERS, theChar) != -1);
|
---|
421 | 00728 }
|
---|
422 | 00729
|
---|
423 | 00730 <font class="keyword">inline</font> <font class="keywordtype">bool</font> XMLUri::isReservedCharacter(<font class="keyword">const</font> XMLCh theChar)
|
---|
424 | 00731 {
|
---|
425 | 00732 <font class="keywordflow">return</font> (<a class="code" href="classXMLString.html#z515_0">XMLString::indexOf</a>(RESERVED_CHARACTERS, theChar) != -1);
|
---|
426 | 00733 }
|
---|
427 | 00734
|
---|
428 | 00735 <font class="keyword">inline</font> <font class="keywordtype">bool</font> XMLUri::isPathCharacter(<font class="keyword">const</font> XMLCh theChar)
|
---|
429 | 00736 {
|
---|
430 | 00737 <font class="keywordflow">return</font> (<a class="code" href="classXMLString.html#z515_0">XMLString::indexOf</a>(PATH_CHARACTERS, theChar) != -1);
|
---|
431 | 00738 }
|
---|
432 | 00739
|
---|
433 | 00740 <font class="keyword">inline</font> <font class="keywordtype">bool</font> XMLUri::isUnreservedCharacter(<font class="keyword">const</font> XMLCh theChar)
|
---|
434 | 00741 {
|
---|
435 | 00742 <font class="keywordflow">return</font> (<a class="code" href="classXMLString.html#z519_17">XMLString::isAlphaNum</a>(theChar) ||
|
---|
436 | 00743 <a class="code" href="classXMLString.html#z515_0">XMLString::indexOf</a>(MARK_CHARACTERS, theChar) != -1);
|
---|
437 | 00744 }
|
---|
438 | 00745
|
---|
439 | 00746 <a class="code" href="XercesDefs_8hpp.html#a3">XERCES_CPP_NAMESPACE_END</a>
|
---|
440 | 00747
|
---|
441 | 00748 <font class="preprocessor">#endif</font>
|
---|
442 | </pre></div> </FONT></TD></TR></TABLE><BR>
|
---|
443 | </TD></TR></TABLE></TD></TR></TABLE><BR><TABLE border="0" cellpadding="0" cellspacing="0" width="620"><TR><TD bgcolor="#0086b2"><IMG height="1" src="images/dot.gif" width="1" alt=""></TD></TR><TR><TD align="center"><FONT color="#0086b2" size="-1"><I>
|
---|
444 | Copyright © 1994-2004 The Apache Software Foundation.
|
---|
445 | All Rights Reserved.
|
---|
446 | </I></FONT></TD></TR></TABLE></BODY></HTML>
|
---|