All About Class Properties in Java

The properties class represents a 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.A property list can contain another property list as its default.In case to search for a key the second list is searched if the property key is not found in the original property list.
The structure of the Class Property is defined as:

public class java.util.Properties extends java.util.Hashtable{
//member element
protected properties defaults;
//A property list which contains default values for any keys not found in the current property list
public Properties();
//creates a an empty Property list with no default values.
public Properties(Properties defaults);
//creates a an empty Property list with default values specified in the argument.
public String getProperty(String key);
public String getProperties(string key,String defaultValue);
public void list(PrintStream out);
public void Load(InputStream in);
public void save(OutputStream out,String header);
public Enumeration PropertiesNames();
All About Class Properties in Java All About Class Properties in Java Reviewed by Animesh Chatterjee on October 01, 2018 Rating: 5

No comments:

Powered by Blogger.