blob: 224de68fb264ebdbaaf857de4dbb2d00ab6b50e1 [file] [log] [blame]
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!-- NewPage -->
<html lang="en">
<head>
<!-- Generated by javadoc (1.8.0_102) on Mon Oct 03 08:48:20 EDT 2016 -->
<title>SystemConfiguration</title>
<meta name="date" content="2016-10-03">
<link rel="stylesheet" type="text/css" href="../../../../stylesheet.css" title="Style">
<script type="text/javascript" src="../../../../script.js"></script>
</head>
<body>
<script type="text/javascript"><!--
try {
if (location.href.indexOf('is-external=true') == -1) {
parent.document.title="SystemConfiguration";
}
}
catch(err) {
}
//-->
var methods = {"i0":9,"i1":9,"i2":9,"i3":9,"i4":9,"i5":9,"i6":9,"i7":9,"i8":9,"i9":9,"i10":9,"i11":9,"i12":9,"i13":9,"i14":9,"i15":9,"i16":9,"i17":9};
var tabs = {65535:["t0","All Methods"],1:["t1","Static Methods"],8:["t4","Concrete Methods"]};
var altColor = "altColor";
var rowColor = "rowColor";
var tableTab = "tableTab";
var activeTableTab = "activeTableTab";
</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
<!-- ========= START OF TOP NAVBAR ======= -->
<div class="topNav"><a name="navbar.top">
<!-- -->
</a>
<div class="skipNav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div>
<a name="navbar.top.firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="class-use/SystemConfiguration.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../index-files/index-1.html">Index</a></li>
<li><a href="../../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li><a href="../../../../org/apache/pirk/utils/StringUtils.html" title="class in org.apache.pirk.utils"><span class="typeNameLink">Prev&nbsp;Class</span></a></li>
<li>Next&nbsp;Class</li>
</ul>
<ul class="navList">
<li><a href="../../../../index.html?org/apache/pirk/utils/SystemConfiguration.html" target="_top">Frames</a></li>
<li><a href="SystemConfiguration.html" target="_top">No&nbsp;Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_top">
<li><a href="../../../../allclasses-noframe.html">All&nbsp;Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_top");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
</div>
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor.summary">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method.summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor.detail">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method.detail">Method</a></li>
</ul>
</div>
<a name="skip.navbar.top">
<!-- -->
</a></div>
<!-- ========= END OF TOP NAVBAR ========= -->
<!-- ======== START OF CLASS DATA ======== -->
<div class="header">
<div class="subTitle">org.apache.pirk.utils</div>
<h2 title="Class SystemConfiguration" class="title">Class SystemConfiguration</h2>
</div>
<div class="contentContainer">
<ul class="inheritance">
<li>java.lang.Object</li>
<li>
<ul class="inheritance">
<li>org.apache.pirk.utils.SystemConfiguration</li>
</ul>
</li>
</ul>
<div class="description">
<ul class="blockList">
<li class="blockList">
<hr>
<br>
<pre>public class <span class="typeNameLabel">SystemConfiguration</span>
extends java.lang.Object</pre>
<div class="block">Manages system properties. At first loading of this class, it will:
<p>
1) Load in the DEFAULT_PROPERTY_FILE, if found on the classpath. (Currently 'pirk.properties')
<p>
2) Load in any properties files in the LOCAL_PROPERTIES_DIR. The filenames must end with '.properties'
<p>
3) Load in properties from the QUERIER_PROPERTIES_FILE and RESPONDER_PROPERTIES_FILE</div>
</li>
</ul>
</div>
<div class="summary">
<ul class="blockList">
<li class="blockList">
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
<ul class="blockList">
<li class="blockList"><a name="constructor.summary">
<!-- -->
</a>
<h3>Constructor Summary</h3>
<table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Constructor Summary table, listing constructors, and an explanation">
<caption><span>Constructors</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colOne" scope="col">Constructor and Description</th>
</tr>
<tr class="altColor">
<td class="colOne"><code><span class="memberNameLink"><a href="../../../../org/apache/pirk/utils/SystemConfiguration.html#SystemConfiguration--">SystemConfiguration</a></span>()</code>&nbsp;</td>
</tr>
</table>
</li>
</ul>
<!-- ========== METHOD SUMMARY =========== -->
<ul class="blockList">
<li class="blockList"><a name="method.summary">
<!-- -->
</a>
<h3>Method Summary</h3>
<table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation">
<caption><span id="t0" class="activeTableTab"><span>All Methods</span><span class="tabEnd">&nbsp;</span></span><span id="t1" class="tableTab"><span><a href="javascript:show(1);">Static Methods</a></span><span class="tabEnd">&nbsp;</span></span><span id="t4" class="tableTab"><span><a href="javascript:show(8);">Concrete Methods</a></span><span class="tabEnd">&nbsp;</span></span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colLast" scope="col">Method and Description</th>
</tr>
<tr id="i0" class="altColor">
<td class="colFirst"><code>static void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/pirk/utils/SystemConfiguration.html#appendProperty-java.lang.String-java.lang.String-">appendProperty</a></span>(java.lang.String&nbsp;propertyName,
java.lang.String&nbsp;value)</code>
<div class="block">Appends a property via a comma separated list</div>
</td>
</tr>
<tr id="i1" class="rowColor">
<td class="colFirst"><code>static boolean</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/pirk/utils/SystemConfiguration.html#getBooleanProperty-java.lang.String-boolean-">getBooleanProperty</a></span>(java.lang.String&nbsp;propertyName,
boolean&nbsp;defaultValue)</code>
<div class="block">Gets the specified property as a <code>boolean</code>, or the default value if the property isn't defined.</div>
</td>
</tr>
<tr id="i2" class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/pirk/utils/SystemConfiguration.html#getIntProperty-java.lang.String-int-">getIntProperty</a></span>(java.lang.String&nbsp;propertyName,
int&nbsp;defaultValue)</code>
<div class="block">Gets the specified property as an <code>int</code>, or the default value if the property isn't found.</div>
</td>
</tr>
<tr id="i3" class="rowColor">
<td class="colFirst"><code>static long</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/pirk/utils/SystemConfiguration.html#getLongProperty-java.lang.String-long-">getLongProperty</a></span>(java.lang.String&nbsp;propertyName,
long&nbsp;defaultValue)</code>
<div class="block">Gets the specified property as an <code>long</code>, or the default value if the property isn't found.</div>
</td>
</tr>
<tr id="i4" class="altColor">
<td class="colFirst"><code>static java.util.Properties</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/pirk/utils/SystemConfiguration.html#getProperties--">getProperties</a></span>()</code>
<div class="block">Return the Properties object maintained by this class.</div>
</td>
</tr>
<tr id="i5" class="rowColor">
<td class="colFirst"><code>static java.lang.String</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/pirk/utils/SystemConfiguration.html#getProperty-java.lang.String-">getProperty</a></span>(java.lang.String&nbsp;propertyName)</code>
<div class="block">Gets the specified property; returns <code>null</code> if the property isn't found.</div>
</td>
</tr>
<tr id="i6" class="altColor">
<td class="colFirst"><code>static java.lang.String</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/pirk/utils/SystemConfiguration.html#getProperty-java.lang.String-java.lang.String-">getProperty</a></span>(java.lang.String&nbsp;propertyName,
java.lang.String&nbsp;defaultValue)</code>
<div class="block">Gets the specified property as a <code>String</code>, or the default value if the property isn't found.</div>
</td>
</tr>
<tr id="i7" class="rowColor">
<td class="colFirst"><code>static boolean</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/pirk/utils/SystemConfiguration.html#hasProperty-java.lang.String-">hasProperty</a></span>(java.lang.String&nbsp;propertyName)</code>
<div class="block">Returns true iff the given property name is defined.</div>
</td>
</tr>
<tr id="i8" class="altColor">
<td class="colFirst"><code>static void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/pirk/utils/SystemConfiguration.html#initialize--">initialize</a></span>()</code>&nbsp;</td>
</tr>
<tr id="i9" class="rowColor">
<td class="colFirst"><code>static boolean</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/pirk/utils/SystemConfiguration.html#isSetTrue-java.lang.String-">isSetTrue</a></span>(java.lang.String&nbsp;propertyName)</code>
<div class="block">Returns <code>true</code> iff the specified boolean property value is "true".</div>
</td>
</tr>
<tr id="i10" class="altColor">
<td class="colFirst"><code>static void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/pirk/utils/SystemConfiguration.html#loadProperties-java.io.InputStream-">loadProperties</a></span>(java.io.InputStream&nbsp;stream)</code>
<div class="block">Load the properties in the Properties object and then trim any whitespace</div>
</td>
</tr>
<tr id="i11" class="rowColor">
<td class="colFirst"><code>static void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/pirk/utils/SystemConfiguration.html#loadPropsFromDir-java.lang.String-">loadPropsFromDir</a></span>(java.lang.String&nbsp;dirName)</code>
<div class="block">Loads the properties from local properties file in the specified directory.</div>
</td>
</tr>
<tr id="i12" class="altColor">
<td class="colFirst"><code>static void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/pirk/utils/SystemConfiguration.html#loadPropsFromFile-java.io.File-">loadPropsFromFile</a></span>(java.io.File&nbsp;file)</code>
<div class="block">Loads the properties from the specified file.</div>
</td>
</tr>
<tr id="i13" class="rowColor">
<td class="colFirst"><code>static void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/pirk/utils/SystemConfiguration.html#loadPropsFromFile-org.apache.hadoop.fs.Path-org.apache.hadoop.fs.FileSystem-">loadPropsFromFile</a></span>(org.apache.hadoop.fs.Path&nbsp;filePath,
org.apache.hadoop.fs.FileSystem&nbsp;fs)</code>
<div class="block">Loads the properties from the specified file in hdfs</div>
</td>
</tr>
<tr id="i14" class="altColor">
<td class="colFirst"><code>static void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/pirk/utils/SystemConfiguration.html#loadPropsFromFile-java.lang.String-org.apache.hadoop.fs.FileSystem-">loadPropsFromFile</a></span>(java.lang.String&nbsp;filename,
org.apache.hadoop.fs.FileSystem&nbsp;fs)</code>
<div class="block">Loads the properties from the specified file in hdfs</div>
</td>
</tr>
<tr id="i15" class="rowColor">
<td class="colFirst"><code>static void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/pirk/utils/SystemConfiguration.html#loadPropsFromHDFSDir-java.lang.String-org.apache.hadoop.fs.FileSystem-">loadPropsFromHDFSDir</a></span>(java.lang.String&nbsp;dirName,
org.apache.hadoop.fs.FileSystem&nbsp;fs)</code>
<div class="block">Loads the properties from local properties file in the specified directory in hdfs.</div>
</td>
</tr>
<tr id="i16" class="altColor">
<td class="colFirst"><code>static void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/pirk/utils/SystemConfiguration.html#loadPropsFromResource-java.lang.String-">loadPropsFromResource</a></span>(java.lang.String&nbsp;name)</code>
<div class="block">Loads the properties from the specified resource on the current classloader.</div>
</td>
</tr>
<tr id="i17" class="rowColor">
<td class="colFirst"><code>static void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../org/apache/pirk/utils/SystemConfiguration.html#setProperty-java.lang.String-java.lang.String-">setProperty</a></span>(java.lang.String&nbsp;propertyName,
java.lang.String&nbsp;value)</code>
<div class="block">Sets the property to the given value.</div>
</td>
</tr>
</table>
<ul class="blockList">
<li class="blockList"><a name="methods.inherited.from.class.java.lang.Object">
<!-- -->
</a>
<h3>Methods inherited from class&nbsp;java.lang.Object</h3>
<code>equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait</code></li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
<div class="details">
<ul class="blockList">
<li class="blockList">
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<ul class="blockList">
<li class="blockList"><a name="constructor.detail">
<!-- -->
</a>
<h3>Constructor Detail</h3>
<a name="SystemConfiguration--">
<!-- -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>SystemConfiguration</h4>
<pre>public&nbsp;SystemConfiguration()</pre>
</li>
</ul>
</li>
</ul>
<!-- ============ METHOD DETAIL ========== -->
<ul class="blockList">
<li class="blockList"><a name="method.detail">
<!-- -->
</a>
<h3>Method Detail</h3>
<a name="initialize--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>initialize</h4>
<pre>public static&nbsp;void&nbsp;initialize()</pre>
</li>
</ul>
<a name="getProperties--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getProperties</h4>
<pre>public static&nbsp;java.util.Properties&nbsp;getProperties()</pre>
<div class="block">Return the Properties object maintained by this class.</div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>The system properties.</dd>
</dl>
</li>
</ul>
<a name="getProperty-java.lang.String-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getProperty</h4>
<pre>public static&nbsp;java.lang.String&nbsp;getProperty(java.lang.String&nbsp;propertyName)</pre>
<div class="block">Gets the specified property; returns <code>null</code> if the property isn't found.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>propertyName</code> - The name of the requested property.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>The value of the property, or <code>null</code> if the property cannot be found.</dd>
</dl>
</li>
</ul>
<a name="getProperty-java.lang.String-java.lang.String-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getProperty</h4>
<pre>public static&nbsp;java.lang.String&nbsp;getProperty(java.lang.String&nbsp;propertyName,
java.lang.String&nbsp;defaultValue)</pre>
<div class="block">Gets the specified property as a <code>String</code>, or the default value if the property isn't found.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>propertyName</code> - The name of the requested string property value.</dd>
<dd><code>defaultValue</code> - The value to return if the property is undefined.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>The value of the requested property, or the default value if the property is undefined.</dd>
</dl>
</li>
</ul>
<a name="getIntProperty-java.lang.String-int-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getIntProperty</h4>
<pre>public static&nbsp;int&nbsp;getIntProperty(java.lang.String&nbsp;propertyName,
int&nbsp;defaultValue)</pre>
<div class="block">Gets the specified property as an <code>int</code>, or the default value if the property isn't found.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>propertyName</code> - The name of the requested int property value.</dd>
<dd><code>defaultValue</code> - The value to return if the property is undefined.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>The value of the requested property, or the default value if the property is undefined.</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code>java.lang.NumberFormatException</code> - If the property does not contain a parsable <code>int</code> value.</dd>
</dl>
</li>
</ul>
<a name="getLongProperty-java.lang.String-long-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getLongProperty</h4>
<pre>public static&nbsp;long&nbsp;getLongProperty(java.lang.String&nbsp;propertyName,
long&nbsp;defaultValue)</pre>
<div class="block">Gets the specified property as an <code>long</code>, or the default value if the property isn't found.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>propertyName</code> - The name of the requested long property value.</dd>
<dd><code>defaultValue</code> - The value to return if the property is undefined.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>The value of the requested property, or the default value if the property is undefined.</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code>java.lang.NumberFormatException</code> - If the property does not contain a parsable <code>long</code> value.</dd>
</dl>
</li>
</ul>
<a name="getBooleanProperty-java.lang.String-boolean-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getBooleanProperty</h4>
<pre>public static&nbsp;boolean&nbsp;getBooleanProperty(java.lang.String&nbsp;propertyName,
boolean&nbsp;defaultValue)</pre>
<div class="block">Gets the specified property as a <code>boolean</code>, or the default value if the property isn't defined.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>propertyName</code> - The name of the requested boolean property value.</dd>
<dd><code>defaultValue</code> - The value to return if the property is undefined.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd><code>true</code> if the property is defined and has the value "true", otherwise <code>defaultValue</code>.</dd>
</dl>
</li>
</ul>
<a name="isSetTrue-java.lang.String-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>isSetTrue</h4>
<pre>public static&nbsp;boolean&nbsp;isSetTrue(java.lang.String&nbsp;propertyName)</pre>
<div class="block">Returns <code>true</code> iff the specified boolean property value is "true".
<p>
If the property is not found, or it's value is not "true" then the method will return <code>false</code>.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>propertyName</code> - The name of the requested boolean property value.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd><code>true</code> if the property is defined and has the value "true", otherwise <code>false</code>.</dd>
</dl>
</li>
</ul>
<a name="setProperty-java.lang.String-java.lang.String-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setProperty</h4>
<pre>public static&nbsp;void&nbsp;setProperty(java.lang.String&nbsp;propertyName,
java.lang.String&nbsp;value)</pre>
<div class="block">Sets the property to the given value.
<p>
Any previous values stored at the same property name are replaced.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>propertyName</code> - The name of the property to set.</dd>
<dd><code>value</code> - The property value.</dd>
</dl>
</li>
</ul>
<a name="hasProperty-java.lang.String-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>hasProperty</h4>
<pre>public static&nbsp;boolean&nbsp;hasProperty(java.lang.String&nbsp;propertyName)</pre>
<div class="block">Returns true iff the given property name is defined.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>propertyName</code> - The property name to test.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd><code>true</code> if the property is found in the configuration, or <code>false</code> otherwise.</dd>
</dl>
</li>
</ul>
<a name="appendProperty-java.lang.String-java.lang.String-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>appendProperty</h4>
<pre>public static&nbsp;void&nbsp;appendProperty(java.lang.String&nbsp;propertyName,
java.lang.String&nbsp;value)</pre>
<div class="block">Appends a property via a comma separated list
<p>
If the property does not exist, it adds it.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>propertyName</code> - The property whose value is to be appended with the given value.</dd>
<dd><code>value</code> - The value to be stored, or appended to the current value.</dd>
</dl>
</li>
</ul>
<a name="loadPropsFromDir-java.lang.String-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>loadPropsFromDir</h4>
<pre>public static&nbsp;void&nbsp;loadPropsFromDir(java.lang.String&nbsp;dirName)</pre>
<div class="block">Loads the properties from local properties file in the specified directory.
<p>
All files ending in '.properties' will be loaded. The new properties are added to the current system configuration.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>dirName</code> - The directory to search for the new properties files.</dd>
</dl>
</li>
</ul>
<a name="loadPropsFromHDFSDir-java.lang.String-org.apache.hadoop.fs.FileSystem-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>loadPropsFromHDFSDir</h4>
<pre>public static&nbsp;void&nbsp;loadPropsFromHDFSDir(java.lang.String&nbsp;dirName,
org.apache.hadoop.fs.FileSystem&nbsp;fs)
throws java.io.FileNotFoundException,
java.io.IOException</pre>
<div class="block">Loads the properties from local properties file in the specified directory in hdfs.
<p>
All files ending in '.properties' will be loaded. The new properties are added to the current system configuration.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>dirName</code> - The directory to search for the new properties files.</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code>java.io.IOException</code></dd>
<dd><code>java.io.FileNotFoundException</code></dd>
</dl>
</li>
</ul>
<a name="loadPropsFromFile-java.io.File-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>loadPropsFromFile</h4>
<pre>public static&nbsp;void&nbsp;loadPropsFromFile(java.io.File&nbsp;file)</pre>
<div class="block">Loads the properties from the specified file.
<p>
The new properties are added to the current system configuration.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>file</code> - The properties file containing the system properties to add.</dd>
</dl>
</li>
</ul>
<a name="loadPropsFromFile-java.lang.String-org.apache.hadoop.fs.FileSystem-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>loadPropsFromFile</h4>
<pre>public static&nbsp;void&nbsp;loadPropsFromFile(java.lang.String&nbsp;filename,
org.apache.hadoop.fs.FileSystem&nbsp;fs)
throws java.io.IOException</pre>
<div class="block">Loads the properties from the specified file in hdfs
<p>
The new properties are added to the current system configuration.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>file</code> - The properties file containing the system properties to add.</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code>java.io.IOException</code></dd>
</dl>
</li>
</ul>
<a name="loadPropsFromFile-org.apache.hadoop.fs.Path-org.apache.hadoop.fs.FileSystem-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>loadPropsFromFile</h4>
<pre>public static&nbsp;void&nbsp;loadPropsFromFile(org.apache.hadoop.fs.Path&nbsp;filePath,
org.apache.hadoop.fs.FileSystem&nbsp;fs)
throws java.io.IOException</pre>
<div class="block">Loads the properties from the specified file in hdfs
<p>
The new properties are added to the current system configuration.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>file</code> - The properties file containing the system properties to add.</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code>java.io.IOException</code></dd>
</dl>
</li>
</ul>
<a name="loadPropsFromResource-java.lang.String-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>loadPropsFromResource</h4>
<pre>public static&nbsp;void&nbsp;loadPropsFromResource(java.lang.String&nbsp;name)</pre>
<div class="block">Loads the properties from the specified resource on the current classloader.
<p>
The new properties are added to the current system configuration.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>name</code> - The name of the resource defining the properties.</dd>
</dl>
</li>
</ul>
<a name="loadProperties-java.io.InputStream-">
<!-- -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>loadProperties</h4>
<pre>public static&nbsp;void&nbsp;loadProperties(java.io.InputStream&nbsp;stream)
throws java.io.IOException</pre>
<div class="block">Load the properties in the Properties object and then trim any whitespace
<p>
Properties.load does not do this automatically</div>
<dl>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code>java.io.IOException</code></dd>
</dl>
</li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
</div>
<!-- ========= END OF CLASS DATA ========= -->
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<div class="bottomNav"><a name="navbar.bottom">
<!-- -->
</a>
<div class="skipNav"><a href="#skip.navbar.bottom" title="Skip navigation links">Skip navigation links</a></div>
<a name="navbar.bottom.firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="class-use/SystemConfiguration.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../index-files/index-1.html">Index</a></li>
<li><a href="../../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li><a href="../../../../org/apache/pirk/utils/StringUtils.html" title="class in org.apache.pirk.utils"><span class="typeNameLink">Prev&nbsp;Class</span></a></li>
<li>Next&nbsp;Class</li>
</ul>
<ul class="navList">
<li><a href="../../../../index.html?org/apache/pirk/utils/SystemConfiguration.html" target="_top">Frames</a></li>
<li><a href="SystemConfiguration.html" target="_top">No&nbsp;Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_bottom">
<li><a href="../../../../allclasses-noframe.html">All&nbsp;Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_bottom");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
</div>
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor.summary">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method.summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor.detail">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method.detail">Method</a></li>
</ul>
</div>
<a name="skip.navbar.bottom">
<!-- -->
</a></div>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
</body>
</html>