You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@struts.apache.org by Oleg V Alexeev <go...@penza.net> on 2001/06/14 07:09:03 UTC
Re[4]: New BeanFactory build
Hello Jonathan,
Thursday, June 14, 2001, 8:23:00 AM, you wrote:
JA> Thanks Oleg. Can you give me a detsiled step-by-step from the point a form
JA> is submitted until the Action perform().
1. Search for list of bean registraions by path (like search for action
mapping)
2. If fine one and it contain any bean registrations then start to
generate beans.
3. Take bean registration, search bean factory and bean template for
it. If not found any - generate error 500 and return false to main
request processing in ActionServlet.process() method.
4. Take bean template, scan parameter mappings, assign values to every
parameter (there is source attribute for parameter mapping in bean
template - you can assign source name to it to aquire value from)
and put all ready to use parameters to the parameters array.
5. Take bean factory (found at step 3), call Factory.create() method
with target type name and array of parameters. This method returns
Object - ref to the created bean. If bean is not created and
'necessary' attribute present in bean registration then error will
be generated.
6. Take 'scope' attribute from bean registration (if it is not exists
then default value will be used - 'request') and store created bean
in specified scope.
The end.
--
Best regards,
Oleg mailto:gonza@penza.net