You shouldn't view Java as programs. What you mean maybe you want a Java CLASS to read an INI file when it is loaded. Follow the example code below:public class A {
static {
try {
FileInputStream fis = new FileInputStream("abc.ini");
fis.read(); // do whatever you need to read the file
}
catch (IOException ioex) {
}
}
// your other class code
...
}
btw, this is nothing related to Collections Framework.
--lichu