• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

How often the listeners as well as filters are used in applications by companies??

 
Ranch Hand
Posts: 142
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I know the theory of listeners & filters.
But have not used yet in my applications anywhen.

How often the listeners as well as filters are used in applications by companies??

Can you guys please share your experience with filters/listeners you used & for what purpose?

thank you.
 
Bartender
Posts: 1561
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Jyoti Vaskar wrote:I know the theory of listeners & filters.
But have not used yet in my applications anywhen.


Have you ever created a GUI application such as a Swing or AWT app?
 
Jyoti Vaskar
Ranch Hand
Posts: 142
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

pete stein wrote:

Jyoti Vaskar wrote:I know the theory of listeners & filters.
But have not used yet in my applications anywhen.


Have you ever created a GUI application such as a Swing or AWT app?



Not actually.
But my question was related to Listeners used with servlets.
 
pete stein
Bartender
Posts: 1561
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Jyoti Vaskar wrote:But I'm asking here for Listeners used with servlets.



I didn't see that mentioned anywhere in the original post.
 
Author
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I don't think I've written a web app that hasn't used both, or their equivalent, ever. Sometimes frameworks introduce their own filters and listeners as well (like Spring's startup listener, or Hibernate's open-session-in-view filter). They're ubiquitous.
 
Jyoti Vaskar
Ranch Hand
Posts: 142
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

David Newton wrote:I don't think I've written a web app that hasn't used both, or their equivalent, ever. Sometimes frameworks introduce their own filters and listeners as well (like Spring's startup listener, or Hibernate's open-session-in-view filter). They're ubiquitous.



thanks for sharing David.
I have a 1 yr of exp in java & hardly worked on any of the big projects at my experience.

I'd be thankfull to you if you can tell the purpose behind the use of it in your application as I'm keen to know its uses.

thank you.
 
David Newton
Author
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I gave two examples; how many would you like?
 
Jyoti Vaskar
Ranch Hand
Posts: 142
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

David Newton wrote:(like Spring's startup listener, or Hibernate's open-session-in-view filter)
I gave two examples; how many would you like?



Yesterday I searched for it & got two examples of listeners ie.
1) Creating a database connection before application starts & closing before it stops.
2) Counting the application startups.

& of filter is
modifying the request parameters before sending it to server.
changing the response before sending it to view etc.

And I got some idea.

Actually from your answer I couldnt even understand what is open-session-in-view & hence couldnt even be able to know that these are examples which you have given??
Hence I'd asked for examples again bymistake :confused:.

Anyways thanks for your co-operation David.
 
David Newton
Author
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You could search for "open session in view", I suppose.

GZIP filters are also a typical filter usage.
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic