Hi,
I have a class to read some property File. I want whenever I will instantiate that class I will pass Array of property File Name or property Object. So that in that proprty reader I will have number of property object as I passed as argument and number argument may varry(sometimes 2 and sometimes it may be 5).
I tried as follow
//Calling class
String[] propName= {"ABC","XYZ"}; // I can pass as many number of object.
PropertyReader.getInstance(propName);
//Called Class
public static PropertyReader getInstance(String[] appCode) {
if(propertyReader == null){
propertyReader = new PropertyReader(appCode);
}
return propertyReader;
}
private PropertyReader(String[] appCode) {// I do not what to write here }
My main aim is as there are two argument as "abc" and "xyz" . there should be two Properties object by name abc and xyz should be created. the no. of object may vary depending upon the # of arguments.
If anyone has any idea please help me understand what to do here .
Rajesh