org.matalon.pagerankhits.conf
Class Configuration

java.lang.Object
  extended byorg.matalon.pagerankhits.conf.Configuration

public class Configuration
extends java.lang.Object

This class is responsible for loading/retrieving web related properties.

Author:
Yonatan Matalon

Field Summary
private  boolean isInitialized
           
private  java.util.Properties properties
           
 
Constructor Summary
Configuration(java.lang.String propertiesFileName)
          Constructor.
 
Method Summary
 boolean getBoolean(java.lang.String key)
           
 int getInt(java.lang.String key)
           
 java.lang.String getString(java.lang.String key)
           
private  void init(java.lang.String propertiesFileName)
          Populates a Properties Object with the content of the given properties file name.
private  void parseLine(java.lang.String line)
          Parses the given key=value line.
 java.util.Collection values()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

properties

private java.util.Properties properties

isInitialized

private boolean isInitialized
Constructor Detail

Configuration

public Configuration(java.lang.String propertiesFileName)
Constructor.

Method Detail

values

public java.util.Collection values()
Returns:
Returns properties' values.

getBoolean

public boolean getBoolean(java.lang.String key)
Parameters:
key -
Returns:
Returns the boolean value of the given key.

getInt

public int getInt(java.lang.String key)
Parameters:
key -
Returns:
Returns the int value of the given key.

getString

public java.lang.String getString(java.lang.String key)
Parameters:
key -
Returns:
Returns the String value of the given key.

init

private void init(java.lang.String propertiesFileName)
Populates a Properties Object with the content of the given properties file name.

Parameters:
propertiesFileName -

parseLine

private void parseLine(java.lang.String line)
Parses the given key=value line.

Parameters:
line -