|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.jboss.soa.esb.helpers.KeyValuePair
public class KeyValuePair
Constructor Summary | |
---|---|
KeyValuePair(java.lang.String pKey,
java.lang.String pVal)
|
Method Summary | |
---|---|
java.lang.String |
dump()
|
static boolean |
getBooleanValue(java.lang.String key,
java.util.List<KeyValuePair> list,
boolean defaultVal)
Get the boolean equivalent value associated with the specified key from the supplied list of Key Value Pairs. |
static double |
getDoubleValue(java.lang.String key,
java.util.List<KeyValuePair> list,
double defaultVal)
Get the numeric double equivalent value associated with the specified key
from the supplied list of Key Value Pairs. |
java.lang.String |
getKey()
|
java.lang.String |
getValue()
|
static java.lang.String |
getValue(java.lang.String key,
java.util.List<KeyValuePair> list)
Get the value associated with the specified key from the supplied list of Key Value Pairs. |
static java.lang.String |
getValue(java.lang.String key,
java.util.List<KeyValuePair> list,
java.lang.String defaultVal)
Get the value associated with the specified key from the supplied list of Key Value Pairs. |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public KeyValuePair(java.lang.String pKey, java.lang.String pVal)
Method Detail |
---|
public java.lang.String getKey()
public java.lang.String getValue()
public java.lang.String toString()
toString
in class java.lang.Object
public java.lang.String dump()
public static java.lang.String getValue(java.lang.String key, java.util.List<KeyValuePair> list)
key
- The key to search for.list
- The list of KeyValuePairs to search.
public static java.lang.String getValue(java.lang.String key, java.util.List<KeyValuePair> list, java.lang.String defaultVal)
key
- The key to search for.list
- The list of KeyValuePairs to search.defaultVal
- The default value to be returned where there's no value available for the specified key.
public static boolean getBooleanValue(java.lang.String key, java.util.List<KeyValuePair> list, boolean defaultVal)
true
: If value equals "true" or "yes" or "y" (ignoring case).false
: If value equals "false" or "no" or "n" (ignoring case).
key
- The key to search for.list
- The list of KeyValuePairs to search.defaultVal
- The default value to be returned where the above listed conditions do not hold
for the associated value, or the value is not specified.
public static double getDoubleValue(java.lang.String key, java.util.List<KeyValuePair> list, double defaultVal)
double
equivalent value associated with the specified key
from the supplied list of Key Value Pairs.
Returns the value from the first matching key.
key
- The key to search for.list
- The list of KeyValuePairs to search.defaultVal
- The default value to be returned where the value is not found or is non-numeric.
double
equivalent value associated with the specified key if the value is found
and is numeric, otherwise the defaultVal is returned.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |