wood burning stoves 2.0*
The moose likes Web Component Certification (SCWCD/OCPJWCD) and the fly likes Order Of Listeners Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Certification » Web Component Certification (SCWCD/OCPJWCD)
Bookmark "Order Of Listeners" Watch "Order Of Listeners" New topic
Author

Order Of Listeners

senthil rajan
Ranch Hand

Joined: Aug 31, 2005
Posts: 36
Hi Frnds,

In which order the listeners will be executed?
Its based on the order in web.xml or will it follow any pattern match like servlets? If so what kind of pattern?

Can anybody give some idea on this??

Thanks,
Senthil.
singh santosh
Ranch Hand

Joined: Jan 13, 2006
Posts: 136
In which order the listeners will be executed?
Its based on the order in web.xml or will it follow any pattern match like servlets? If so what kind of pattern


its based on the order of web.xml .The order of listenrs in web.xml form a filter chain.Lets say u have declared three listeners A,B,C in this order
so there will be kind of filterchain

A->B->C known to FilterChain interface.
So if ur request/response qualifies for A it will proccesed down the chain in the chains order..

I hope this is clear .Correct me if I am wrong..

regards
-santosh
Narendra Dhande
Ranch Hand

Joined: Dec 04, 2004
Posts: 950
Hi,

The Listener are executed when the particular event is triggered. In case there are more than one Listeners are definded of the same type, they follow the order as defined in the web.xml.

Thanks


Narendra Dhande
SCJP 1.4,SCWCD 1.4, SCBCD 5.0, SCDJWS 5.0, SCEA 5.0
singh santosh
Ranch Hand

Joined: Jan 13, 2006
Posts: 136
hi senthil,
I m sorry as i did a seroius mistake ,when i read ur question i got Filters in my mind dont know why?
So my answer is valid if ur was about Filters order ,i hope u get what i want to say.. Sorry for this mistake..

regards
-santsoh
 
jQuery in Action, 2nd edition
 
subject: Order Of Listeners