ehcache

net.sf.ehcache.util
Class PropertyUtil

java.lang.Object
  extended by net.sf.ehcache.util.PropertyUtil

public final class PropertyUtil
extends Object

Property utilities.

Version:
$Id: PropertyUtil.java 5594 2012-05-07 16:04:31Z cdennis $
Author:
Greg Luck

Method Summary
static String extractAndLogProperty(String name, Map properties)
           
static String extractAndLogProperty(String name, Properties properties)
           
static boolean parseBoolean(String value)
          Null safe, parser of boolean from a String
static Properties parseProperties(String propertiesString, String propertySeparator)
          Parse properties supplied as a comma separated list into a Properties object
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

extractAndLogProperty

public static String extractAndLogProperty(String name,
                                           Properties properties)
Returns:
null if their is no property for the key, or their are no properties

extractAndLogProperty

public static String extractAndLogProperty(String name,
                                           Map properties)
Returns:
null if their is no property for the key, or their are no properties

parseProperties

public static Properties parseProperties(String propertiesString,
                                         String propertySeparator)
Parse properties supplied as a comma separated list into a Properties object

Parameters:
propertiesString - a comma separated list such as "propertyA=s, propertyB=t"
Returns:
a newly constructed properties object

parseBoolean

public static boolean parseBoolean(String value)
Null safe, parser of boolean from a String

Parameters:
value -
Returns:
true if non null and case insensitively matches true

ehcache

Copyright 2001-2015, Terracotta, Inc.