1 | <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
|
---|
2 | <!--NewPage-->
|
---|
3 | <HTML>
|
---|
4 | <HEAD>
|
---|
5 | <!-- Generated by javadoc (build 1.4.2_13) on Mon Oct 01 14:33:34 NZST 2007 -->
|
---|
6 | <TITLE>
|
---|
7 | DOMElementWriter (Apache Ant API)
|
---|
8 | </TITLE>
|
---|
9 |
|
---|
10 | <META NAME="keywords" CONTENT="org.apache.tools.ant.util.DOMElementWriter class">
|
---|
11 |
|
---|
12 | <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
|
---|
13 |
|
---|
14 | <SCRIPT type="text/javascript">
|
---|
15 | function windowTitle()
|
---|
16 | {
|
---|
17 | parent.document.title="DOMElementWriter (Apache Ant API)";
|
---|
18 | }
|
---|
19 | </SCRIPT>
|
---|
20 |
|
---|
21 | </HEAD>
|
---|
22 |
|
---|
23 | <BODY BGCOLOR="white" onload="windowTitle();">
|
---|
24 |
|
---|
25 |
|
---|
26 | <!-- ========= START OF TOP NAVBAR ======= -->
|
---|
27 | <A NAME="navbar_top"><!-- --></A>
|
---|
28 | <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
|
---|
29 | <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
|
---|
30 | <TR>
|
---|
31 | <TD COLSPAN=3 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
|
---|
32 | <A NAME="navbar_top_firstrow"><!-- --></A>
|
---|
33 | <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
|
---|
34 | <TR ALIGN="center" VALIGN="top">
|
---|
35 | <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A> </TD>
|
---|
36 | <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD>
|
---|
37 | <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD>
|
---|
38 | <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD>
|
---|
39 | <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD>
|
---|
40 | <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD>
|
---|
41 | <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD>
|
---|
42 | </TR>
|
---|
43 | </TABLE>
|
---|
44 | </TD>
|
---|
45 | <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
|
---|
46 | </EM>
|
---|
47 | </TD>
|
---|
48 | </TR>
|
---|
49 |
|
---|
50 | <TR>
|
---|
51 | <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
|
---|
52 | <A HREF="../../../../../org/apache/tools/ant/util/DateUtils.html" title="class in org.apache.tools.ant.util"><B>PREV CLASS</B></A>
|
---|
53 | <A HREF="../../../../../org/apache/tools/ant/util/DOMUtils.html" title="class in org.apache.tools.ant.util"><B>NEXT CLASS</B></A></FONT></TD>
|
---|
54 | <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
|
---|
55 | <A HREF="../../../../../index.html" target="_top"><B>FRAMES</B></A>
|
---|
56 | <A HREF="DOMElementWriter.html" target="_top"><B>NO FRAMES</B></A>
|
---|
57 | <SCRIPT type="text/javascript">
|
---|
58 | <!--
|
---|
59 | if(window==top) {
|
---|
60 | document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
|
---|
61 | }
|
---|
62 | //-->
|
---|
63 | </SCRIPT>
|
---|
64 | <NOSCRIPT>
|
---|
65 | <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>
|
---|
66 | </NOSCRIPT>
|
---|
67 |
|
---|
68 | </FONT></TD>
|
---|
69 | </TR>
|
---|
70 | <TR>
|
---|
71 | <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
|
---|
72 | SUMMARY: NESTED | <A HREF="#field_summary">FIELD</A> | <A HREF="#constructor_summary">CONSTR</A> | <A HREF="#method_summary">METHOD</A></FONT></TD>
|
---|
73 | <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
|
---|
74 | DETAIL: <A HREF="#field_detail">FIELD</A> | <A HREF="#constructor_detail">CONSTR</A> | <A HREF="#method_detail">METHOD</A></FONT></TD>
|
---|
75 | </TR>
|
---|
76 | </TABLE>
|
---|
77 | <A NAME="skip-navbar_top"></A>
|
---|
78 | <!-- ========= END OF TOP NAVBAR ========= -->
|
---|
79 |
|
---|
80 | <HR>
|
---|
81 | <!-- ======== START OF CLASS DATA ======== -->
|
---|
82 | <H2>
|
---|
83 | <FONT SIZE="-1">
|
---|
84 | org.apache.tools.ant.util</FONT>
|
---|
85 | <BR>
|
---|
86 | Class DOMElementWriter</H2>
|
---|
87 | <PRE>
|
---|
88 | java.lang.Object
|
---|
89 | <IMG SRC="../../../../../resources/inherit.gif" ALT="extended by"><B>org.apache.tools.ant.util.DOMElementWriter</B>
|
---|
90 | </PRE>
|
---|
91 | <HR>
|
---|
92 | <DL>
|
---|
93 | <DT>public class <B>DOMElementWriter</B><DT>extends java.lang.Object</DL>
|
---|
94 |
|
---|
95 | <P>
|
---|
96 | Writes a DOM tree to a given Writer.
|
---|
97 |
|
---|
98 | <p>Utility class used by <A HREF="../../../../../org/apache/tools/ant/XmlLogger.html" title="class in org.apache.tools.ant"><CODE>XmlLogger</CODE></A> and
|
---|
99 | org.apache.tools.ant.taskdefs.optional.junit.XMLJUnitResultFormatter
|
---|
100 | XMLJUnitResultFormatter}.</p>
|
---|
101 | <P>
|
---|
102 |
|
---|
103 | <P>
|
---|
104 | <HR>
|
---|
105 |
|
---|
106 | <P>
|
---|
107 | <!-- ======== NESTED CLASS SUMMARY ======== -->
|
---|
108 |
|
---|
109 |
|
---|
110 | <!-- =========== FIELD SUMMARY =========== -->
|
---|
111 |
|
---|
112 | <A NAME="field_summary"><!-- --></A>
|
---|
113 | <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
|
---|
114 | <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
|
---|
115 | <TD COLSPAN=2><FONT SIZE="+2">
|
---|
116 | <B>Field Summary</B></FONT></TD>
|
---|
117 | </TR>
|
---|
118 | <TR BGCOLOR="white" CLASS="TableRowColor">
|
---|
119 | <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
---|
120 | <CODE>protected java.lang.String[]</CODE></FONT></TD>
|
---|
121 | <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/DOMElementWriter.html#knownEntities">knownEntities</A></B></CODE>
|
---|
122 |
|
---|
123 | <BR>
|
---|
124 | Don't try to be too smart but at least recognize the predefined
|
---|
125 | entities.</TD>
|
---|
126 | </TR>
|
---|
127 | </TABLE>
|
---|
128 |
|
---|
129 | <!-- ======== CONSTRUCTOR SUMMARY ======== -->
|
---|
130 |
|
---|
131 | <A NAME="constructor_summary"><!-- --></A>
|
---|
132 | <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
|
---|
133 | <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
|
---|
134 | <TD COLSPAN=2><FONT SIZE="+2">
|
---|
135 | <B>Constructor Summary</B></FONT></TD>
|
---|
136 | </TR>
|
---|
137 | <TR BGCOLOR="white" CLASS="TableRowColor">
|
---|
138 | <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/DOMElementWriter.html#DOMElementWriter()">DOMElementWriter</A></B>()</CODE>
|
---|
139 |
|
---|
140 | <BR>
|
---|
141 | </TD>
|
---|
142 | </TR>
|
---|
143 | </TABLE>
|
---|
144 |
|
---|
145 | <!-- ========== METHOD SUMMARY =========== -->
|
---|
146 |
|
---|
147 | <A NAME="method_summary"><!-- --></A>
|
---|
148 | <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
|
---|
149 | <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
|
---|
150 | <TD COLSPAN=2><FONT SIZE="+2">
|
---|
151 | <B>Method Summary</B></FONT></TD>
|
---|
152 | </TR>
|
---|
153 | <TR BGCOLOR="white" CLASS="TableRowColor">
|
---|
154 | <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
---|
155 | <CODE> void</CODE></FONT></TD>
|
---|
156 | <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/DOMElementWriter.html#closeElement(org.w3c.dom.Element, java.io.Writer, int, java.lang.String, boolean)">closeElement</A></B>(org.w3c.dom.Element element,
|
---|
157 | java.io.Writer out,
|
---|
158 | int indent,
|
---|
159 | java.lang.String indentWith,
|
---|
160 | boolean hasChildren)</CODE>
|
---|
161 |
|
---|
162 | <BR>
|
---|
163 | Writes a DOM tree to a stream.</TD>
|
---|
164 | </TR>
|
---|
165 | <TR BGCOLOR="white" CLASS="TableRowColor">
|
---|
166 | <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
---|
167 | <CODE> java.lang.String</CODE></FONT></TD>
|
---|
168 | <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/DOMElementWriter.html#encode(java.lang.String)">encode</A></B>(java.lang.String value)</CODE>
|
---|
169 |
|
---|
170 | <BR>
|
---|
171 | Escape <, > & ', " as their entities and
|
---|
172 | drop characters that are illegal in XML documents.</TD>
|
---|
173 | </TR>
|
---|
174 | <TR BGCOLOR="white" CLASS="TableRowColor">
|
---|
175 | <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
---|
176 | <CODE> java.lang.String</CODE></FONT></TD>
|
---|
177 | <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/DOMElementWriter.html#encodedata(java.lang.String)">encodedata</A></B>(java.lang.String value)</CODE>
|
---|
178 |
|
---|
179 | <BR>
|
---|
180 | Drop characters that are illegal in XML documents.</TD>
|
---|
181 | </TR>
|
---|
182 | <TR BGCOLOR="white" CLASS="TableRowColor">
|
---|
183 | <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
---|
184 | <CODE> boolean</CODE></FONT></TD>
|
---|
185 | <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/DOMElementWriter.html#isLegalCharacter(char)">isLegalCharacter</A></B>(char c)</CODE>
|
---|
186 |
|
---|
187 | <BR>
|
---|
188 | Is the given character allowed inside an XML document?
|
---|
189 |
|
---|
190 | </TD>
|
---|
191 | </TR>
|
---|
192 | <TR BGCOLOR="white" CLASS="TableRowColor">
|
---|
193 | <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
---|
194 | <CODE> boolean</CODE></FONT></TD>
|
---|
195 | <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/DOMElementWriter.html#isReference(java.lang.String)">isReference</A></B>(java.lang.String ent)</CODE>
|
---|
196 |
|
---|
197 | <BR>
|
---|
198 | Is the given argument a character or entity reference?</TD>
|
---|
199 | </TR>
|
---|
200 | <TR BGCOLOR="white" CLASS="TableRowColor">
|
---|
201 | <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
---|
202 | <CODE> void</CODE></FONT></TD>
|
---|
203 | <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/DOMElementWriter.html#openElement(org.w3c.dom.Element, java.io.Writer, int, java.lang.String)">openElement</A></B>(org.w3c.dom.Element element,
|
---|
204 | java.io.Writer out,
|
---|
205 | int indent,
|
---|
206 | java.lang.String indentWith)</CODE>
|
---|
207 |
|
---|
208 | <BR>
|
---|
209 | Writes the opening tag - including all attributes -
|
---|
210 | correspondong to a DOM element.</TD>
|
---|
211 | </TR>
|
---|
212 | <TR BGCOLOR="white" CLASS="TableRowColor">
|
---|
213 | <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
---|
214 | <CODE> void</CODE></FONT></TD>
|
---|
215 | <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/DOMElementWriter.html#write(org.w3c.dom.Element, java.io.OutputStream)">write</A></B>(org.w3c.dom.Element root,
|
---|
216 | java.io.OutputStream out)</CODE>
|
---|
217 |
|
---|
218 | <BR>
|
---|
219 | Writes a DOM tree to a stream in UTF8 encoding.</TD>
|
---|
220 | </TR>
|
---|
221 | <TR BGCOLOR="white" CLASS="TableRowColor">
|
---|
222 | <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
|
---|
223 | <CODE> void</CODE></FONT></TD>
|
---|
224 | <TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/DOMElementWriter.html#write(org.w3c.dom.Element, java.io.Writer, int, java.lang.String)">write</A></B>(org.w3c.dom.Element element,
|
---|
225 | java.io.Writer out,
|
---|
226 | int indent,
|
---|
227 | java.lang.String indentWith)</CODE>
|
---|
228 |
|
---|
229 | <BR>
|
---|
230 | Writes a DOM tree to a stream.</TD>
|
---|
231 | </TR>
|
---|
232 | </TABLE>
|
---|
233 | <A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
|
---|
234 | <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
|
---|
235 | <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
|
---|
236 | <TD><B>Methods inherited from class java.lang.Object</B></TD>
|
---|
237 | </TR>
|
---|
238 | <TR BGCOLOR="white" CLASS="TableRowColor">
|
---|
239 | <TD><CODE>clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait</CODE></TD>
|
---|
240 | </TR>
|
---|
241 | </TABLE>
|
---|
242 |
|
---|
243 | <P>
|
---|
244 |
|
---|
245 | <!-- ============ FIELD DETAIL =========== -->
|
---|
246 |
|
---|
247 | <A NAME="field_detail"><!-- --></A>
|
---|
248 | <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
|
---|
249 | <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
|
---|
250 | <TD COLSPAN=1><FONT SIZE="+2">
|
---|
251 | <B>Field Detail</B></FONT></TD>
|
---|
252 | </TR>
|
---|
253 | </TABLE>
|
---|
254 |
|
---|
255 | <A NAME="knownEntities"><!-- --></A><H3>
|
---|
256 | knownEntities</H3>
|
---|
257 | <PRE>
|
---|
258 | protected java.lang.String[] <B>knownEntities</B></PRE>
|
---|
259 | <DL>
|
---|
260 | <DD>Don't try to be too smart but at least recognize the predefined
|
---|
261 | entities.
|
---|
262 | <P>
|
---|
263 | <DL>
|
---|
264 | </DL>
|
---|
265 | </DL>
|
---|
266 |
|
---|
267 | <!-- ========= CONSTRUCTOR DETAIL ======== -->
|
---|
268 |
|
---|
269 | <A NAME="constructor_detail"><!-- --></A>
|
---|
270 | <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
|
---|
271 | <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
|
---|
272 | <TD COLSPAN=1><FONT SIZE="+2">
|
---|
273 | <B>Constructor Detail</B></FONT></TD>
|
---|
274 | </TR>
|
---|
275 | </TABLE>
|
---|
276 |
|
---|
277 | <A NAME="DOMElementWriter()"><!-- --></A><H3>
|
---|
278 | DOMElementWriter</H3>
|
---|
279 | <PRE>
|
---|
280 | public <B>DOMElementWriter</B>()</PRE>
|
---|
281 | <DL>
|
---|
282 | </DL>
|
---|
283 |
|
---|
284 | <!-- ============ METHOD DETAIL ========== -->
|
---|
285 |
|
---|
286 | <A NAME="method_detail"><!-- --></A>
|
---|
287 | <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
|
---|
288 | <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
|
---|
289 | <TD COLSPAN=1><FONT SIZE="+2">
|
---|
290 | <B>Method Detail</B></FONT></TD>
|
---|
291 | </TR>
|
---|
292 | </TABLE>
|
---|
293 |
|
---|
294 | <A NAME="write(org.w3c.dom.Element, java.io.OutputStream)"><!-- --></A><H3>
|
---|
295 | write</H3>
|
---|
296 | <PRE>
|
---|
297 | public void <B>write</B>(org.w3c.dom.Element root,
|
---|
298 | java.io.OutputStream out)
|
---|
299 | throws java.io.IOException</PRE>
|
---|
300 | <DL>
|
---|
301 | <DD>Writes a DOM tree to a stream in UTF8 encoding. Note that
|
---|
302 | it prepends the <?xml version='1.0' encoding='UTF-8'?>.
|
---|
303 | The indent number is set to 0 and a 2-space indent.
|
---|
304 | <P>
|
---|
305 | <DD><DL>
|
---|
306 | <DT><B>Parameters:</B><DD><CODE>root</CODE> - the root element of the DOM tree.<DD><CODE>out</CODE> - the outputstream to write to.
|
---|
307 | <DT><B>Throws:</B>
|
---|
308 | <DD><CODE>java.io.IOException</CODE> - if an error happens while writing to the stream.</DL>
|
---|
309 | </DD>
|
---|
310 | </DL>
|
---|
311 | <HR>
|
---|
312 |
|
---|
313 | <A NAME="write(org.w3c.dom.Element, java.io.Writer, int, java.lang.String)"><!-- --></A><H3>
|
---|
314 | write</H3>
|
---|
315 | <PRE>
|
---|
316 | public void <B>write</B>(org.w3c.dom.Element element,
|
---|
317 | java.io.Writer out,
|
---|
318 | int indent,
|
---|
319 | java.lang.String indentWith)
|
---|
320 | throws java.io.IOException</PRE>
|
---|
321 | <DL>
|
---|
322 | <DD>Writes a DOM tree to a stream.
|
---|
323 | <P>
|
---|
324 | <DD><DL>
|
---|
325 | <DT><B>Parameters:</B><DD><CODE>element</CODE> - the Root DOM element of the tree<DD><CODE>out</CODE> - where to send the output<DD><CODE>indent</CODE> - number of<DD><CODE>indentWith</CODE> - string that should be used to indent the corresponding tag.
|
---|
326 | <DT><B>Throws:</B>
|
---|
327 | <DD><CODE>java.io.IOException</CODE> - if an error happens while writing to the stream.</DL>
|
---|
328 | </DD>
|
---|
329 | </DL>
|
---|
330 | <HR>
|
---|
331 |
|
---|
332 | <A NAME="openElement(org.w3c.dom.Element, java.io.Writer, int, java.lang.String)"><!-- --></A><H3>
|
---|
333 | openElement</H3>
|
---|
334 | <PRE>
|
---|
335 | public void <B>openElement</B>(org.w3c.dom.Element element,
|
---|
336 | java.io.Writer out,
|
---|
337 | int indent,
|
---|
338 | java.lang.String indentWith)
|
---|
339 | throws java.io.IOException</PRE>
|
---|
340 | <DL>
|
---|
341 | <DD>Writes the opening tag - including all attributes -
|
---|
342 | correspondong to a DOM element.
|
---|
343 | <P>
|
---|
344 | <DD><DL>
|
---|
345 | <DT><B>Parameters:</B><DD><CODE>element</CODE> - the DOM element to write<DD><CODE>out</CODE> - where to send the output<DD><CODE>indent</CODE> - number of<DD><CODE>indentWith</CODE> - string that should be used to indent the
|
---|
346 | corresponding tag.
|
---|
347 | <DT><B>Throws:</B>
|
---|
348 | <DD><CODE>java.io.IOException</CODE> - if an error happens while writing to the stream.</DL>
|
---|
349 | </DD>
|
---|
350 | </DL>
|
---|
351 | <HR>
|
---|
352 |
|
---|
353 | <A NAME="closeElement(org.w3c.dom.Element, java.io.Writer, int, java.lang.String, boolean)"><!-- --></A><H3>
|
---|
354 | closeElement</H3>
|
---|
355 | <PRE>
|
---|
356 | public void <B>closeElement</B>(org.w3c.dom.Element element,
|
---|
357 | java.io.Writer out,
|
---|
358 | int indent,
|
---|
359 | java.lang.String indentWith,
|
---|
360 | boolean hasChildren)
|
---|
361 | throws java.io.IOException</PRE>
|
---|
362 | <DL>
|
---|
363 | <DD>Writes a DOM tree to a stream.
|
---|
364 | <P>
|
---|
365 | <DD><DL>
|
---|
366 | <DT><B>Parameters:</B><DD><CODE>element</CODE> - the Root DOM element of the tree<DD><CODE>out</CODE> - where to send the output<DD><CODE>indent</CODE> - number of<DD><CODE>indentWith</CODE> - string that should be used to indent the
|
---|
367 | corresponding tag.
|
---|
368 | <DT><B>Throws:</B>
|
---|
369 | <DD><CODE>java.io.IOException</CODE> - if an error happens while writing to the stream.</DL>
|
---|
370 | </DD>
|
---|
371 | </DL>
|
---|
372 | <HR>
|
---|
373 |
|
---|
374 | <A NAME="encode(java.lang.String)"><!-- --></A><H3>
|
---|
375 | encode</H3>
|
---|
376 | <PRE>
|
---|
377 | public java.lang.String <B>encode</B>(java.lang.String value)</PRE>
|
---|
378 | <DL>
|
---|
379 | <DD>Escape <, > & ', " as their entities and
|
---|
380 | drop characters that are illegal in XML documents.
|
---|
381 | <P>
|
---|
382 | <DD><DL>
|
---|
383 | </DL>
|
---|
384 | </DD>
|
---|
385 | </DL>
|
---|
386 | <HR>
|
---|
387 |
|
---|
388 | <A NAME="encodedata(java.lang.String)"><!-- --></A><H3>
|
---|
389 | encodedata</H3>
|
---|
390 | <PRE>
|
---|
391 | public java.lang.String <B>encodedata</B>(java.lang.String value)</PRE>
|
---|
392 | <DL>
|
---|
393 | <DD>Drop characters that are illegal in XML documents.
|
---|
394 |
|
---|
395 | <p>Also ensure that we are not including an <code>]]></code>
|
---|
396 | marker by replacing that sequence with
|
---|
397 | <code>&#x5d;&#x5d;&gt;</code>.</p>
|
---|
398 |
|
---|
399 | <p>See XML 1.0 2.2 <a
|
---|
400 | href="http://www.w3.org/TR/1998/REC-xml-19980210#charsets">http://www.w3.org/TR/1998/REC-xml-19980210#charsets</a> and
|
---|
401 | 2.7 <a
|
---|
402 | href="http://www.w3.org/TR/1998/REC-xml-19980210#sec-cdata-sect">http://www.w3.org/TR/1998/REC-xml-19980210#sec-cdata-sect</a>.</p>
|
---|
403 | <P>
|
---|
404 | <DD><DL>
|
---|
405 | </DL>
|
---|
406 | </DD>
|
---|
407 | </DL>
|
---|
408 | <HR>
|
---|
409 |
|
---|
410 | <A NAME="isReference(java.lang.String)"><!-- --></A><H3>
|
---|
411 | isReference</H3>
|
---|
412 | <PRE>
|
---|
413 | public boolean <B>isReference</B>(java.lang.String ent)</PRE>
|
---|
414 | <DL>
|
---|
415 | <DD>Is the given argument a character or entity reference?
|
---|
416 | <P>
|
---|
417 | <DD><DL>
|
---|
418 | </DL>
|
---|
419 | </DD>
|
---|
420 | </DL>
|
---|
421 | <HR>
|
---|
422 |
|
---|
423 | <A NAME="isLegalCharacter(char)"><!-- --></A><H3>
|
---|
424 | isLegalCharacter</H3>
|
---|
425 | <PRE>
|
---|
426 | public boolean <B>isLegalCharacter</B>(char c)</PRE>
|
---|
427 | <DL>
|
---|
428 | <DD>Is the given character allowed inside an XML document?
|
---|
429 |
|
---|
430 | <p>See XML 1.0 2.2 <a
|
---|
431 | href="http://www.w3.org/TR/1998/REC-xml-19980210#charsets">
|
---|
432 | http://www.w3.org/TR/1998/REC-xml-19980210#charsets</a>.</p>
|
---|
433 | <P>
|
---|
434 | <DD><DL>
|
---|
435 | <DT><B>Since:</B></DT>
|
---|
436 | <DD>1.10, Ant 1.5</DD>
|
---|
437 | </DL>
|
---|
438 | </DD>
|
---|
439 | </DL>
|
---|
440 | <!-- ========= END OF CLASS DATA ========= -->
|
---|
441 | <HR>
|
---|
442 |
|
---|
443 |
|
---|
444 | <!-- ======= START OF BOTTOM NAVBAR ====== -->
|
---|
445 | <A NAME="navbar_bottom"><!-- --></A>
|
---|
446 | <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
|
---|
447 | <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
|
---|
448 | <TR>
|
---|
449 | <TD COLSPAN=3 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
|
---|
450 | <A NAME="navbar_bottom_firstrow"><!-- --></A>
|
---|
451 | <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
|
---|
452 | <TR ALIGN="center" VALIGN="top">
|
---|
453 | <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A> </TD>
|
---|
454 | <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD>
|
---|
455 | <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD>
|
---|
456 | <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD>
|
---|
457 | <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD>
|
---|
458 | <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD>
|
---|
459 | <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD>
|
---|
460 | </TR>
|
---|
461 | </TABLE>
|
---|
462 | </TD>
|
---|
463 | <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
|
---|
464 | </EM>
|
---|
465 | </TD>
|
---|
466 | </TR>
|
---|
467 |
|
---|
468 | <TR>
|
---|
469 | <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
|
---|
470 | <A HREF="../../../../../org/apache/tools/ant/util/DateUtils.html" title="class in org.apache.tools.ant.util"><B>PREV CLASS</B></A>
|
---|
471 | <A HREF="../../../../../org/apache/tools/ant/util/DOMUtils.html" title="class in org.apache.tools.ant.util"><B>NEXT CLASS</B></A></FONT></TD>
|
---|
472 | <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
|
---|
473 | <A HREF="../../../../../index.html" target="_top"><B>FRAMES</B></A>
|
---|
474 | <A HREF="DOMElementWriter.html" target="_top"><B>NO FRAMES</B></A>
|
---|
475 | <SCRIPT type="text/javascript">
|
---|
476 | <!--
|
---|
477 | if(window==top) {
|
---|
478 | document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
|
---|
479 | }
|
---|
480 | //-->
|
---|
481 | </SCRIPT>
|
---|
482 | <NOSCRIPT>
|
---|
483 | <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>
|
---|
484 | </NOSCRIPT>
|
---|
485 |
|
---|
486 | </FONT></TD>
|
---|
487 | </TR>
|
---|
488 | <TR>
|
---|
489 | <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
|
---|
490 | SUMMARY: NESTED | <A HREF="#field_summary">FIELD</A> | <A HREF="#constructor_summary">CONSTR</A> | <A HREF="#method_summary">METHOD</A></FONT></TD>
|
---|
491 | <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
|
---|
492 | DETAIL: <A HREF="#field_detail">FIELD</A> | <A HREF="#constructor_detail">CONSTR</A> | <A HREF="#method_detail">METHOD</A></FONT></TD>
|
---|
493 | </TR>
|
---|
494 | </TABLE>
|
---|
495 | <A NAME="skip-navbar_bottom"></A>
|
---|
496 | <!-- ======== END OF BOTTOM NAVBAR ======= -->
|
---|
497 |
|
---|
498 | <HR>
|
---|
499 | Copyright © 2000-2007 Apache Software Foundation. All Rights Reserved.
|
---|
500 | </BODY>
|
---|
501 | </HTML>
|
---|