java - Trigger function when Undeploying application -


Text "itemprop =" text ">

contextDestroyed () Apply and hook on

Basic Example:

  Public Class Config Elements ServletContextListener {Public Zero Reference Start (ServletContextEvent Event) {// Write a code here, which should be executed on WebApp startup. } Public Zero ReferenceStored (ServletContextEvent Event) {// here is the code that should be executed on webpage shutdown. }}  

and call it and lt; Listener & gt; Register as web.xml in .

  & lt; Listener & gt; & Lt; Audience category & gt; Com.example.Config & lt; / Listener Category & gt; & Lt; / Listener & gt;  

Comments

Popular posts from this blog

c# - How to capture HTTP packet with SharpPcap -

jquery - SimpleModal Confirm fails to submit form -

php - Multiple Select with Explode: only returns the word "Array" -