public final class Properties extends Object
Modifier and Type | Method and Description |
---|---|
static PropertyEntry |
create(String key,
String value) |
static String |
get(Collection<PropertyEntry> properties,
String key,
String defaultValue) |
static String |
getProperty(Collection<PropertyEntry> properties,
String name,
String defaultValue) |
static boolean |
isEmpty(PropertyEntry entry)
Test if either the key or the value is empty of null
|
static Boolean |
isProperty(Collection<PropertyEntry> properties,
String name,
Boolean defaultValue) |
static Map<String,String> |
makeAttributes(Collection<PropertyEntry> properties) |
static Map<String,String> |
makeAttributes(String prefix,
Collection<PropertyEntry> properties) |
static void |
putNonEmpty(Map<String,String> properties,
String key,
String value) |
public static PropertyEntry create(String key, String value)
public static String getProperty(Collection<PropertyEntry> properties, String name, String defaultValue)
public static String get(Collection<PropertyEntry> properties, String key, String defaultValue)
public static Map<String,String> makeAttributes(Collection<PropertyEntry> properties)
public static Map<String,String> makeAttributes(String prefix, Collection<PropertyEntry> properties)
public static Boolean isProperty(Collection<PropertyEntry> properties, String name, Boolean defaultValue)
public static boolean isEmpty(PropertyEntry entry)
entry
- the entry to testtrue
if either key or value are empty or null