Basically the instantiate() method provides a way for code to dynamically load and use JavaBeans without knowing too much about them...
As for the beanName, the JavaDoc states (under the third instantantiate() method, the one with 4 parameters...) -
In Beans 1.0 the given name can indicate either a serialized object or a class. Other mechanisms may be added in the future. In beans 1.0 we first try to treat the beanName as a serialized object name then as a class name.
When using the beanName as a serialized object name we convert the given beanName to a resource pathname and add a trailing ".ser" suffix. We then try to load a serialized object from that resource.
So, basically, beanName either gives the full class name of the bean, or it gives the name of a file that holds a serialized bean.
(NEP - edited to correctly quote the JavaDoc.) [ October 19, 2005: Message edited by: Nathan Pruett ]
Write once, run anywhere, because there's nowhere to hide! - /. A.C.