java.util.Properties
The Properties class represents a persistent set of properties. The Properties can be saved to a stream or loaded from a stream. Each key and its corresponding value in the property list is a string.
Some more Methods of Properties class.
clear(): This method Clears this hashtable so that it contains no keys.
clone(): This method creates a shallow copy of this hashtable.
compute(Object, BiFunction): This method computes the values according to the mapping function.
computeIfAbsent(Object, Function): If the specified key is not already associated with a value attempt to compute its value using the given mapping function and enter it into this property unless null.
computeIfPresent(Object, BiFunction): If the value for the specified key is present and non-null, attempts to compute a new mapping given the key and its current mapped value.
contains(Object): This method tests if some keymaps into the specified value in this hashtable.
containsKey(Object): This method tests if the specified object is a key in this hashtable.
containsValue(Object): This method returns true if this hashtable maps one or more keys to this value.
elements(): This method returns an enumeration of the values in this hashtable.
entrySet(): This method returns a Set view of the mappings contained in this map.
equals(Object): This method compares the specified Object with this Map for equality.
forEach(BiConsumer): his method performs the given action for each entry in this map until all entries have been processed or the action throws an exception.
get(Object): This method returns the value to which the specified key is mapped, or null if this map contains no mapping for the key.
getOrDefault(Object, Object): This method returns the value to which the specified key is mapped, or defaultValue if this map contains no mapping for the key.
getProperty(String): This method searches for the property with the specified key in this property list.
Some more Methods of Properties class Part -II
Some more Methods of Properties class Part -III
No comments:
Post a Comment