source: other-projects/trunk/gs3-release-maker/apache-ant-1.6.5/build/javadocs/org/apache/tools/ant/util/LoaderUtils.html@ 14627

Last change on this file since 14627 was 14627, checked in by oranfry, 17 years ago

initial import of the gs3-release-maker

File size: 13.5 KB
Line 
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:35 NZST 2007 -->
6<TITLE>
7LoaderUtils (Apache Ant API)
8</TITLE>
9
10<META NAME="keywords" CONTENT="org.apache.tools.ant.util.LoaderUtils class">
11
12<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">
13
14<SCRIPT type="text/javascript">
15function windowTitle()
16{
17 parent.document.title="LoaderUtils (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>&nbsp;</TD>
36 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
37 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
38 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
39 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
40 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
41 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</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&nbsp;<A HREF="../../../../../org/apache/tools/ant/util/LineTokenizer.html" title="class in org.apache.tools.ant.util"><B>PREV CLASS</B></A>&nbsp;
53&nbsp;<A HREF="../../../../../org/apache/tools/ant/util/MergingMapper.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> &nbsp;
56&nbsp;<A HREF="LoaderUtils.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
57&nbsp;<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:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
73<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
74DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<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">
84org.apache.tools.ant.util</FONT>
85<BR>
86Class LoaderUtils</H2>
87<PRE>
88java.lang.Object
89 <IMG SRC="../../../../../resources/inherit.gif" ALT="extended by"><B>org.apache.tools.ant.util.LoaderUtils</B>
90</PRE>
91<HR>
92<DL>
93<DT>public class <B>LoaderUtils</B><DT>extends java.lang.Object</DL>
94
95<P>
96ClassLoader utility methods
97<P>
98
99<P>
100<HR>
101
102<P>
103<!-- ======== NESTED CLASS SUMMARY ======== -->
104
105
106<!-- =========== FIELD SUMMARY =========== -->
107
108
109<!-- ======== CONSTRUCTOR SUMMARY ======== -->
110
111<A NAME="constructor_summary"><!-- --></A>
112<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
113<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
114<TD COLSPAN=2><FONT SIZE="+2">
115<B>Constructor Summary</B></FONT></TD>
116</TR>
117<TR BGCOLOR="white" CLASS="TableRowColor">
118<TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/LoaderUtils.html#LoaderUtils()">LoaderUtils</A></B>()</CODE>
119
120<BR>
121&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
122</TR>
123</TABLE>
124&nbsp;
125<!-- ========== METHOD SUMMARY =========== -->
126
127<A NAME="method_summary"><!-- --></A>
128<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
129<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
130<TD COLSPAN=2><FONT SIZE="+2">
131<B>Method Summary</B></FONT></TD>
132</TR>
133<TR BGCOLOR="white" CLASS="TableRowColor">
134<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
135<CODE>static&nbsp;java.io.File</CODE></FONT></TD>
136<TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/LoaderUtils.html#getClassSource(java.lang.Class)">getClassSource</A></B>(java.lang.Class&nbsp;c)</CODE>
137
138<BR>
139&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Find the directory or jar file the class has been loaded from.</TD>
140</TR>
141<TR BGCOLOR="white" CLASS="TableRowColor">
142<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
143<CODE>static&nbsp;java.lang.ClassLoader</CODE></FONT></TD>
144<TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/LoaderUtils.html#getContextClassLoader()">getContextClassLoader</A></B>()</CODE>
145
146<BR>
147&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;JDK1.1 compatible access to set the context class loader.</TD>
148</TR>
149<TR BGCOLOR="white" CLASS="TableRowColor">
150<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
151<CODE>static&nbsp;java.io.File</CODE></FONT></TD>
152<TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/LoaderUtils.html#getResourceSource(java.lang.ClassLoader, java.lang.String)">getResourceSource</A></B>(java.lang.ClassLoader&nbsp;c,
153 java.lang.String&nbsp;resource)</CODE>
154
155<BR>
156&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Find the directory or a give resource has been loaded from.</TD>
157</TR>
158<TR BGCOLOR="white" CLASS="TableRowColor">
159<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
160<CODE>static&nbsp;boolean</CODE></FONT></TD>
161<TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/LoaderUtils.html#isContextLoaderAvailable()">isContextLoaderAvailable</A></B>()</CODE>
162
163<BR>
164&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Indicates if the context class loader methods are available</TD>
165</TR>
166<TR BGCOLOR="white" CLASS="TableRowColor">
167<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
168<CODE>static&nbsp;void</CODE></FONT></TD>
169<TD><CODE><B><A HREF="../../../../../org/apache/tools/ant/util/LoaderUtils.html#setContextClassLoader(java.lang.ClassLoader)">setContextClassLoader</A></B>(java.lang.ClassLoader&nbsp;loader)</CODE>
170
171<BR>
172&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Set the context classloader</TD>
173</TR>
174</TABLE>
175&nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
176<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
177<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
178<TD><B>Methods inherited from class java.lang.Object</B></TD>
179</TR>
180<TR BGCOLOR="white" CLASS="TableRowColor">
181<TD><CODE>clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait</CODE></TD>
182</TR>
183</TABLE>
184&nbsp;
185<P>
186
187<!-- ============ FIELD DETAIL =========== -->
188
189
190<!-- ========= CONSTRUCTOR DETAIL ======== -->
191
192<A NAME="constructor_detail"><!-- --></A>
193<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
194<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
195<TD COLSPAN=1><FONT SIZE="+2">
196<B>Constructor Detail</B></FONT></TD>
197</TR>
198</TABLE>
199
200<A NAME="LoaderUtils()"><!-- --></A><H3>
201LoaderUtils</H3>
202<PRE>
203public <B>LoaderUtils</B>()</PRE>
204<DL>
205</DL>
206
207<!-- ============ METHOD DETAIL ========== -->
208
209<A NAME="method_detail"><!-- --></A>
210<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
211<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
212<TD COLSPAN=1><FONT SIZE="+2">
213<B>Method Detail</B></FONT></TD>
214</TR>
215</TABLE>
216
217<A NAME="setContextClassLoader(java.lang.ClassLoader)"><!-- --></A><H3>
218setContextClassLoader</H3>
219<PRE>
220public static void <B>setContextClassLoader</B>(java.lang.ClassLoader&nbsp;loader)</PRE>
221<DL>
222<DD>Set the context classloader
223<P>
224<DD><DL>
225<DT><B>Parameters:</B><DD><CODE>loader</CODE> - the ClassLoader to be used as the context class loader
226 on the current thread.</DL>
227</DD>
228</DL>
229<HR>
230
231<A NAME="getContextClassLoader()"><!-- --></A><H3>
232getContextClassLoader</H3>
233<PRE>
234public static java.lang.ClassLoader <B>getContextClassLoader</B>()</PRE>
235<DL>
236<DD>JDK1.1 compatible access to set the context class loader.
237<P>
238<DD><DL>
239
240<DT><B>Returns:</B><DD>the ClassLoader instance being used as the context
241 classloader on the current thread. Returns null on JDK 1.1</DL>
242</DD>
243</DL>
244<HR>
245
246<A NAME="isContextLoaderAvailable()"><!-- --></A><H3>
247isContextLoaderAvailable</H3>
248<PRE>
249public static boolean <B>isContextLoaderAvailable</B>()</PRE>
250<DL>
251<DD>Indicates if the context class loader methods are available
252<P>
253<DD><DL>
254
255<DT><B>Returns:</B><DD>true if the get and set methods dealing with the context
256 classloader are available.</DL>
257</DD>
258</DL>
259<HR>
260
261<A NAME="getClassSource(java.lang.Class)"><!-- --></A><H3>
262getClassSource</H3>
263<PRE>
264public static java.io.File <B>getClassSource</B>(java.lang.Class&nbsp;c)</PRE>
265<DL>
266<DD>Find the directory or jar file the class has been loaded from.
267<P>
268<DD><DL>
269<DT><B>Parameters:</B><DD><CODE>c</CODE> - the class whose location is required.
270<DT><B>Returns:</B><DD>the file or jar with the class or null if we cannot
271 determine the location.<DT><B>Since:</B></DT>
272 <DD>Ant 1.6</DD>
273</DL>
274</DD>
275</DL>
276<HR>
277
278<A NAME="getResourceSource(java.lang.ClassLoader, java.lang.String)"><!-- --></A><H3>
279getResourceSource</H3>
280<PRE>
281public static java.io.File <B>getResourceSource</B>(java.lang.ClassLoader&nbsp;c,
282 java.lang.String&nbsp;resource)</PRE>
283<DL>
284<DD>Find the directory or a give resource has been loaded from.
285<P>
286<DD><DL>
287<DT><B>Parameters:</B><DD><CODE>c</CODE> - the classloader to be consulted for the source<DD><CODE>resource</CODE> - the resource whose location is required.
288<DT><B>Returns:</B><DD>the file with the resource source or null if
289 we cannot determine the location.<DT><B>Since:</B></DT>
290 <DD>Ant 1.6</DD>
291</DL>
292</DD>
293</DL>
294<!-- ========= END OF CLASS DATA ========= -->
295<HR>
296
297
298<!-- ======= START OF BOTTOM NAVBAR ====== -->
299<A NAME="navbar_bottom"><!-- --></A>
300<A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
301<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
302<TR>
303<TD COLSPAN=3 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
304<A NAME="navbar_bottom_firstrow"><!-- --></A>
305<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
306 <TR ALIGN="center" VALIGN="top">
307 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
308 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
309 <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
310 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
311 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
312 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
313 <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
314 </TR>
315</TABLE>
316</TD>
317<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
318</EM>
319</TD>
320</TR>
321
322<TR>
323<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
324&nbsp;<A HREF="../../../../../org/apache/tools/ant/util/LineTokenizer.html" title="class in org.apache.tools.ant.util"><B>PREV CLASS</B></A>&nbsp;
325&nbsp;<A HREF="../../../../../org/apache/tools/ant/util/MergingMapper.html" title="class in org.apache.tools.ant.util"><B>NEXT CLASS</B></A></FONT></TD>
326<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
327 <A HREF="../../../../../index.html" target="_top"><B>FRAMES</B></A> &nbsp;
328&nbsp;<A HREF="LoaderUtils.html" target="_top"><B>NO FRAMES</B></A> &nbsp;
329&nbsp;<SCRIPT type="text/javascript">
330 <!--
331 if(window==top) {
332 document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
333 }
334 //-->
335</SCRIPT>
336<NOSCRIPT>
337 <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>
338</NOSCRIPT>
339
340</FONT></TD>
341</TR>
342<TR>
343<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
344 SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
345<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
346DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
347</TR>
348</TABLE>
349<A NAME="skip-navbar_bottom"></A>
350<!-- ======== END OF BOTTOM NAVBAR ======= -->
351
352<HR>
353Copyright © 2000-2007 Apache Software Foundation. All Rights Reserved.
354</BODY>
355</HTML>
Note: See TracBrowser for help on using the repository browser.