org.apache.commons.validator
Class ValidatorUtil
java.lang.Object
|
+--org.apache.commons.validator.ValidatorUtil
- public class ValidatorUtil
- extends java.lang.Object
Basic utility methods.
- Version:
- $Revision: 1.6 $ $Date: 2002/12/15 21:46:41 $
- Author:
- David Winterfeldt
Field Summary |
protected static org.apache.commons.logging.Log |
log
Logger |
Method Summary |
static org.apache.commons.collections.FastHashMap |
copyFastHashMap(org.apache.commons.collections.FastHashMap map)
Makes a deep copy of a FastHashMap if the values
are String , Msg , Arg ,
or Var . |
static java.lang.String |
getValueAsString(java.lang.Object bean,
java.lang.String property)
Convenience method for getting a value from a bean property as a String . |
static java.lang.String |
replace(java.lang.String value,
java.lang.String key,
java.lang.String replaceValue)
Replace part of a String with another value. |
Methods inherited from class java.lang.Object |
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait |
log
protected static org.apache.commons.logging.Log log
- Logger
ValidatorUtil
public ValidatorUtil()
replace
public static java.lang.String replace(java.lang.String value,
java.lang.String key,
java.lang.String replaceValue)
Replace part of a String
with another value.
- Parameters:
value
- String
to perform the replacement on.key
- The name of the constant.replaceValue
- The value of the constant.
getValueAsString
public static java.lang.String getValueAsString(java.lang.Object bean,
java.lang.String property)
- Convenience method for getting a value from a bean property as a
String
.
copyFastHashMap
public static org.apache.commons.collections.FastHashMap copyFastHashMap(org.apache.commons.collections.FastHashMap map)
- Makes a deep copy of a
FastHashMap
if the values
are String
, Msg
, Arg
,
or Var
. Otherwise it is a shallow copy.
- Parameters:
map
- FastHashMap
to copy.- Returns:
- FastHashMap A copy of the
FastHashMap
that was passed in.
Copyright (c) 2001-2002 - Apache Software Foundation