• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

ActionForm method call sequence

 
wrushasen dakhane
Ranch Hand
Posts: 47
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi ,

Can anybody tell the sequence of the methods that are called when any new request come and the ActionForm gets pouplated?

And also when the form which is already in session then in that case what will be the sequence.

I am little confuse in this.

Wrushu
 
Merrill Higginson
Ranch Hand
Posts: 4864
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Here is the sequence of events as I understand them.
  • Check to see if there is an existing bean in the declared scope. If no bean exists, instantiate one ant put it in the declared scope
  • Call reset()
  • Evaluate the contents of the request and call setter methods on the bean as necessary
  • If the action mapping specifies validate="true" call validate()

  • [ April 13, 2007: Message edited by: Merrill Higginson ]
     
    wrushasen dakhane
    Ranch Hand
    Posts: 47
    • Mark post as helpful
    • send pies
    • Quote
    • Report post to moderator
    What if the form bean doesn't already exits in the scope?

    Will the reset() method will get called on that?
     
    Brent Sterling
    Ranch Hand
    Posts: 948
    • Mark post as helpful
    • send pies
    • Quote
    • Report post to moderator
    I am pretty sure that reset will always get called. I use request scope 99% of the time so I seldom ever (never?) write a reset method.

    - Brent
     
    • Post Reply
    • Bookmark Topic Watch Topic
    • New Topic