net.sourceforge.cobertura.util
Class ConfigurationUtil

java.lang.Object
  extended bynet.sourceforge.cobertura.util.ConfigurationUtil

public class ConfigurationUtil
extends java.lang.Object

A Utility Class to load the configuration. Checks for values using the following hierarchy. 1) System Property matching key. 2) cobertura.properties Resource Property matching key. 3) hardcoded default value

Author:
Joakim Erdfelt

Field Summary
private  java.util.Properties props
           
static java.lang.String RESOURCE
           
 
Constructor Summary
ConfigurationUtil()
           
 
Method Summary
private  void DEBUG(java.lang.String msg)
          Poor mans debugging.
 java.lang.String getDatafile()
           
 java.lang.String getProperty(java.lang.String key, java.lang.String defvalue)
           
 void init()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

RESOURCE

public static final java.lang.String RESOURCE
See Also:
Constant Field Values

props

private java.util.Properties props
Constructor Detail

ConfigurationUtil

public ConfigurationUtil()
Method Detail

init

public void init()

getProperty

public java.lang.String getProperty(java.lang.String key,
                                    java.lang.String defvalue)

getDatafile

public java.lang.String getDatafile()

DEBUG

private void DEBUG(java.lang.String msg)
Poor mans debugging. Intentionally didn't use log4j, as we dont want to introduce that dependency on instrumented files.