source: proiecte/HadoopJUnit/hadoop-0.20.1/docs/api/org/apache/hadoop/metrics/ContextFactory.html @ 120

Last change on this file since 120 was 120, checked in by (none), 14 years ago

Added the mail files for the Hadoop JUNit Project

  • Property svn:executable set to *
File size: 25.0 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.6.0_07) on Tue Sep 01 20:56:54 UTC 2009 -->
6<TITLE>
7ContextFactory (Hadoop 0.20.1 API)
8</TITLE>
9
10<META NAME="date" CONTENT="2009-09-01">
11
12<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
13
14<SCRIPT type="text/javascript">
15function windowTitle()
16{
17    if (location.href.indexOf('is-external=true') == -1) {
18        parent.document.title="ContextFactory (Hadoop 0.20.1 API)";
19    }
20}
21</SCRIPT>
22<NOSCRIPT>
23</NOSCRIPT>
24
25</HEAD>
26
27<BODY BGCOLOR="white" onload="windowTitle();">
28<HR>
29
30
31<!-- ========= START OF TOP NAVBAR ======= -->
32<A NAME="navbar_top"><!-- --></A>
33<A HREF="#skip-navbar_top" title="Skip navigation links"></A>
34<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
35<TR>
36<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
37<A NAME="navbar_top_firstrow"><!-- --></A>
38<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
39  <TR ALIGN="center" VALIGN="top">
40  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
41  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
42  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
43  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="class-use/ContextFactory.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
44  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
45  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
46  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
47  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
48  </TR>
49</TABLE>
50</TD>
51<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
52</EM>
53</TD>
54</TR>
55
56<TR>
57<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
58&nbsp;PREV CLASS&nbsp;
59&nbsp;<A HREF="../../../../org/apache/hadoop/metrics/MetricsContext.html" title="interface in org.apache.hadoop.metrics"><B>NEXT CLASS</B></A></FONT></TD>
60<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
61  <A HREF="../../../../index.html?org/apache/hadoop/metrics/ContextFactory.html" target="_top"><B>FRAMES</B></A>  &nbsp;
62&nbsp;<A HREF="ContextFactory.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;
63&nbsp;<SCRIPT type="text/javascript">
64  <!--
65  if(window==top) {
66    document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
67  }
68  //-->
69</SCRIPT>
70<NOSCRIPT>
71  <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
72</NOSCRIPT>
73
74
75</FONT></TD>
76</TR>
77<TR>
78<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
79  SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
80<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
81DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
82</TR>
83</TABLE>
84<A NAME="skip-navbar_top"></A>
85<!-- ========= END OF TOP NAVBAR ========= -->
86
87<HR>
88<!-- ======== START OF CLASS DATA ======== -->
89<H2>
90<FONT SIZE="-1">
91org.apache.hadoop.metrics</FONT>
92<BR>
93Class ContextFactory</H2>
94<PRE>
95<A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</A>
96  <IMG SRC="../../../../resources/inherit.gif" ALT="extended by "><B>org.apache.hadoop.metrics.ContextFactory</B>
97</PRE>
98<HR>
99<DL>
100<DT><PRE>public class <B>ContextFactory</B><DT>extends <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></DL>
101</PRE>
102
103<P>
104Factory class for creating MetricsContext objects.  To obtain an instance
105 of this class, use the static <code>getFactory()</code> method.
106<P>
107
108<P>
109<HR>
110
111<P>
112
113<!-- ======== CONSTRUCTOR SUMMARY ======== -->
114
115<A NAME="constructor_summary"><!-- --></A>
116<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
117<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
118<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
119<B>Constructor Summary</B></FONT></TH>
120</TR>
121<TR BGCOLOR="white" CLASS="TableRowColor">
122<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
123<CODE>protected </CODE></FONT></TD>
124<TD><CODE><B><A HREF="../../../../org/apache/hadoop/metrics/ContextFactory.html#ContextFactory()">ContextFactory</A></B>()</CODE>
125
126<BR>
127&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Creates a new instance of ContextFactory</TD>
128</TR>
129</TABLE>
130&nbsp;
131<!-- ========== METHOD SUMMARY =========== -->
132
133<A NAME="method_summary"><!-- --></A>
134<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
135<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
136<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
137<B>Method Summary</B></FONT></TH>
138</TR>
139<TR BGCOLOR="white" CLASS="TableRowColor">
140<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
141<CODE>&nbsp;<A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></CODE></FONT></TD>
142<TD><CODE><B><A HREF="../../../../org/apache/hadoop/metrics/ContextFactory.html#getAttribute(java.lang.String)">getAttribute</A></B>(<A HREF="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;attributeName)</CODE>
143
144<BR>
145&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the value of the named attribute, or null if there is no
146 attribute of that name.</TD>
147</TR>
148<TR BGCOLOR="white" CLASS="TableRowColor">
149<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
150<CODE>&nbsp;<A HREF="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>[]</CODE></FONT></TD>
151<TD><CODE><B><A HREF="../../../../org/apache/hadoop/metrics/ContextFactory.html#getAttributeNames()">getAttributeNames</A></B>()</CODE>
152
153<BR>
154&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the names of all the factory's attributes.</TD>
155</TR>
156<TR BGCOLOR="white" CLASS="TableRowColor">
157<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
158<CODE>&nbsp;<A HREF="../../../../org/apache/hadoop/metrics/MetricsContext.html" title="interface in org.apache.hadoop.metrics">MetricsContext</A></CODE></FONT></TD>
159<TD><CODE><B><A HREF="../../../../org/apache/hadoop/metrics/ContextFactory.html#getContext(java.lang.String)">getContext</A></B>(<A HREF="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;contextName)</CODE>
160
161<BR>
162&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD>
163</TR>
164<TR BGCOLOR="white" CLASS="TableRowColor">
165<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
166<CODE>&nbsp;<A HREF="../../../../org/apache/hadoop/metrics/MetricsContext.html" title="interface in org.apache.hadoop.metrics">MetricsContext</A></CODE></FONT></TD>
167<TD><CODE><B><A HREF="../../../../org/apache/hadoop/metrics/ContextFactory.html#getContext(java.lang.String, java.lang.String)">getContext</A></B>(<A HREF="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;refName,
168           <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;contextName)</CODE>
169
170<BR>
171&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the named MetricsContext instance, constructing it if necessary
172 using the factory's current configuration attributes.</TD>
173</TR>
174<TR BGCOLOR="white" CLASS="TableRowColor">
175<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
176<CODE>static&nbsp;<A HREF="../../../../org/apache/hadoop/metrics/ContextFactory.html" title="class in org.apache.hadoop.metrics">ContextFactory</A></CODE></FONT></TD>
177<TD><CODE><B><A HREF="../../../../org/apache/hadoop/metrics/ContextFactory.html#getFactory()">getFactory</A></B>()</CODE>
178
179<BR>
180&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the singleton ContextFactory instance, constructing it if
181 necessary.</TD>
182</TR>
183<TR BGCOLOR="white" CLASS="TableRowColor">
184<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
185<CODE>static&nbsp;<A HREF="../../../../org/apache/hadoop/metrics/MetricsContext.html" title="interface in org.apache.hadoop.metrics">MetricsContext</A></CODE></FONT></TD>
186<TD><CODE><B><A HREF="../../../../org/apache/hadoop/metrics/ContextFactory.html#getNullContext(java.lang.String)">getNullContext</A></B>(<A HREF="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;contextName)</CODE>
187
188<BR>
189&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns a "null" context - one which does nothing.</TD>
190</TR>
191<TR BGCOLOR="white" CLASS="TableRowColor">
192<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
193<CODE>&nbsp;void</CODE></FONT></TD>
194<TD><CODE><B><A HREF="../../../../org/apache/hadoop/metrics/ContextFactory.html#removeAttribute(java.lang.String)">removeAttribute</A></B>(<A HREF="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;attributeName)</CODE>
195
196<BR>
197&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Removes the named attribute if it exists.</TD>
198</TR>
199<TR BGCOLOR="white" CLASS="TableRowColor">
200<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
201<CODE>&nbsp;void</CODE></FONT></TD>
202<TD><CODE><B><A HREF="../../../../org/apache/hadoop/metrics/ContextFactory.html#setAttribute(java.lang.String, java.lang.Object)">setAttribute</A></B>(<A HREF="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;attributeName,
203             <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;value)</CODE>
204
205<BR>
206&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the named factory attribute to the specified value, creating it
207 if it did not already exist.</TD>
208</TR>
209</TABLE>
210&nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
211<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
212<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
213<TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A></B></TH>
214</TR>
215<TR BGCOLOR="white" CLASS="TableRowColor">
216<TD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#clone()" title="class or interface in java.lang">clone</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.lang">equals</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#finalize()" title="class or interface in java.lang">finalize</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#getClass()" title="class or interface in java.lang">getClass</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#hashCode()" title="class or interface in java.lang">hashCode</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#notify()" title="class or interface in java.lang">notify</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#notifyAll()" title="class or interface in java.lang">notifyAll</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#toString()" title="class or interface in java.lang">toString</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#wait()" title="class or interface in java.lang">wait</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#wait(long)" title="class or interface in java.lang">wait</A>, <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</A></CODE></TD>
217</TR>
218</TABLE>
219&nbsp;
220<P>
221
222<!-- ========= CONSTRUCTOR DETAIL ======== -->
223
224<A NAME="constructor_detail"><!-- --></A>
225<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
226<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
227<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
228<B>Constructor Detail</B></FONT></TH>
229</TR>
230</TABLE>
231
232<A NAME="ContextFactory()"><!-- --></A><H3>
233ContextFactory</H3>
234<PRE>
235protected <B>ContextFactory</B>()</PRE>
236<DL>
237<DD>Creates a new instance of ContextFactory
238<P>
239</DL>
240
241<!-- ============ METHOD DETAIL ========== -->
242
243<A NAME="method_detail"><!-- --></A>
244<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
245<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
246<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
247<B>Method Detail</B></FONT></TH>
248</TR>
249</TABLE>
250
251<A NAME="getAttribute(java.lang.String)"><!-- --></A><H3>
252getAttribute</H3>
253<PRE>
254public <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A> <B>getAttribute</B>(<A HREF="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;attributeName)</PRE>
255<DL>
256<DD>Returns the value of the named attribute, or null if there is no
257 attribute of that name.
258<P>
259<DD><DL>
260<DT><B>Parameters:</B><DD><CODE>attributeName</CODE> - the attribute name
261<DT><B>Returns:</B><DD>the attribute value</DL>
262</DD>
263</DL>
264<HR>
265
266<A NAME="getAttributeNames()"><!-- --></A><H3>
267getAttributeNames</H3>
268<PRE>
269public <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>[] <B>getAttributeNames</B>()</PRE>
270<DL>
271<DD>Returns the names of all the factory's attributes.
272<P>
273<DD><DL>
274
275<DT><B>Returns:</B><DD>the attribute names</DL>
276</DD>
277</DL>
278<HR>
279
280<A NAME="setAttribute(java.lang.String, java.lang.Object)"><!-- --></A><H3>
281setAttribute</H3>
282<PRE>
283public void <B>setAttribute</B>(<A HREF="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;attributeName,
284                         <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</A>&nbsp;value)</PRE>
285<DL>
286<DD>Sets the named factory attribute to the specified value, creating it
287 if it did not already exist.  If the value is null, this is the same as
288 calling removeAttribute.
289<P>
290<DD><DL>
291<DT><B>Parameters:</B><DD><CODE>attributeName</CODE> - the attribute name<DD><CODE>value</CODE> - the new attribute value</DL>
292</DD>
293</DL>
294<HR>
295
296<A NAME="removeAttribute(java.lang.String)"><!-- --></A><H3>
297removeAttribute</H3>
298<PRE>
299public void <B>removeAttribute</B>(<A HREF="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;attributeName)</PRE>
300<DL>
301<DD>Removes the named attribute if it exists.
302<P>
303<DD><DL>
304<DT><B>Parameters:</B><DD><CODE>attributeName</CODE> - the attribute name</DL>
305</DD>
306</DL>
307<HR>
308
309<A NAME="getContext(java.lang.String, java.lang.String)"><!-- --></A><H3>
310getContext</H3>
311<PRE>
312public <A HREF="../../../../org/apache/hadoop/metrics/MetricsContext.html" title="interface in org.apache.hadoop.metrics">MetricsContext</A> <B>getContext</B>(<A HREF="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;refName,
313                                 <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;contextName)
314                          throws <A HREF="http://java.sun.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A>,
315                                 <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/ClassNotFoundException.html?is-external=true" title="class or interface in java.lang">ClassNotFoundException</A>,
316                                 <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/InstantiationException.html?is-external=true" title="class or interface in java.lang">InstantiationException</A>,
317                                 <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/IllegalAccessException.html?is-external=true" title="class or interface in java.lang">IllegalAccessException</A></PRE>
318<DL>
319<DD>Returns the named MetricsContext instance, constructing it if necessary
320 using the factory's current configuration attributes. <p/>
321 
322 When constructing the instance, if the factory property
323 <i>contextName</i>.class</code> exists,
324 its value is taken to be the name of the class to instantiate.  Otherwise,
325 the default is to create an instance of
326 <code>org.apache.hadoop.metrics.spi.NullContext</code>, which is a
327 dummy "no-op" context which will cause all metric data to be discarded.
328<P>
329<DD><DL>
330<DT><B>Parameters:</B><DD><CODE>contextName</CODE> - the name of the context
331<DT><B>Returns:</B><DD>the named MetricsContext
332<DT><B>Throws:</B>
333<DD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE>
334<DD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/lang/ClassNotFoundException.html?is-external=true" title="class or interface in java.lang">ClassNotFoundException</A></CODE>
335<DD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/lang/InstantiationException.html?is-external=true" title="class or interface in java.lang">InstantiationException</A></CODE>
336<DD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/lang/IllegalAccessException.html?is-external=true" title="class or interface in java.lang">IllegalAccessException</A></CODE></DL>
337</DD>
338</DL>
339<HR>
340
341<A NAME="getContext(java.lang.String)"><!-- --></A><H3>
342getContext</H3>
343<PRE>
344public <A HREF="../../../../org/apache/hadoop/metrics/MetricsContext.html" title="interface in org.apache.hadoop.metrics">MetricsContext</A> <B>getContext</B>(<A HREF="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;contextName)
345                          throws <A HREF="http://java.sun.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A>,
346                                 <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/ClassNotFoundException.html?is-external=true" title="class or interface in java.lang">ClassNotFoundException</A>,
347                                 <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/InstantiationException.html?is-external=true" title="class or interface in java.lang">InstantiationException</A>,
348                                 <A HREF="http://java.sun.com/javase/6/docs/api/java/lang/IllegalAccessException.html?is-external=true" title="class or interface in java.lang">IllegalAccessException</A></PRE>
349<DL>
350<DD><DL>
351
352<DT><B>Throws:</B>
353<DD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE>
354<DD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/lang/ClassNotFoundException.html?is-external=true" title="class or interface in java.lang">ClassNotFoundException</A></CODE>
355<DD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/lang/InstantiationException.html?is-external=true" title="class or interface in java.lang">InstantiationException</A></CODE>
356<DD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/lang/IllegalAccessException.html?is-external=true" title="class or interface in java.lang">IllegalAccessException</A></CODE></DL>
357</DD>
358</DL>
359<HR>
360
361<A NAME="getNullContext(java.lang.String)"><!-- --></A><H3>
362getNullContext</H3>
363<PRE>
364public static <A HREF="../../../../org/apache/hadoop/metrics/MetricsContext.html" title="interface in org.apache.hadoop.metrics">MetricsContext</A> <B>getNullContext</B>(<A HREF="http://java.sun.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</A>&nbsp;contextName)</PRE>
365<DL>
366<DD>Returns a "null" context - one which does nothing.
367<P>
368<DD><DL>
369</DL>
370</DD>
371</DL>
372<HR>
373
374<A NAME="getFactory()"><!-- --></A><H3>
375getFactory</H3>
376<PRE>
377public static <A HREF="../../../../org/apache/hadoop/metrics/ContextFactory.html" title="class in org.apache.hadoop.metrics">ContextFactory</A> <B>getFactory</B>()
378                                 throws <A HREF="http://java.sun.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></PRE>
379<DL>
380<DD>Returns the singleton ContextFactory instance, constructing it if
381 necessary. <p/>
382 
383 When the instance is constructed, this method checks if the file
384 <code>hadoop-metrics.properties</code> exists on the class path.  If it
385 exists, it must be in the format defined by java.util.Properties, and all
386 the properties in the file are set as attributes on the newly created
387 ContextFactory instance.
388<P>
389<DD><DL>
390
391<DT><B>Returns:</B><DD>the singleton ContextFactory instance
392<DT><B>Throws:</B>
393<DD><CODE><A HREF="http://java.sun.com/javase/6/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</A></CODE></DL>
394</DD>
395</DL>
396<!-- ========= END OF CLASS DATA ========= -->
397<HR>
398
399
400<!-- ======= START OF BOTTOM NAVBAR ====== -->
401<A NAME="navbar_bottom"><!-- --></A>
402<A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
403<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
404<TR>
405<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
406<A NAME="navbar_bottom_firstrow"><!-- --></A>
407<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
408  <TR ALIGN="center" VALIGN="top">
409  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
410  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
411  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
412  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="class-use/ContextFactory.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD>
413  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
414  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
415  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
416  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
417  </TR>
418</TABLE>
419</TD>
420<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
421</EM>
422</TD>
423</TR>
424
425<TR>
426<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
427&nbsp;PREV CLASS&nbsp;
428&nbsp;<A HREF="../../../../org/apache/hadoop/metrics/MetricsContext.html" title="interface in org.apache.hadoop.metrics"><B>NEXT CLASS</B></A></FONT></TD>
429<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
430  <A HREF="../../../../index.html?org/apache/hadoop/metrics/ContextFactory.html" target="_top"><B>FRAMES</B></A>  &nbsp;
431&nbsp;<A HREF="ContextFactory.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;
432&nbsp;<SCRIPT type="text/javascript">
433  <!--
434  if(window==top) {
435    document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>');
436  }
437  //-->
438</SCRIPT>
439<NOSCRIPT>
440  <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>
441</NOSCRIPT>
442
443
444</FONT></TD>
445</TR>
446<TR>
447<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
448  SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
449<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
450DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
451</TR>
452</TABLE>
453<A NAME="skip-navbar_bottom"></A>
454<!-- ======== END OF BOTTOM NAVBAR ======= -->
455
456<HR>
457Copyright &copy; 2009 The Apache Software Foundation
458</BODY>
459</HTML>
Note: See TracBrowser for help on using the repository browser.