/** * Destroys the given managed bean. * @param name * @param instance */ public void destroy(String name, Object instance) { if (instance != null && isManagedBean(name)) { try { _lifecycleProvider.destroyInstance(instance); } catch (IllegalAccessException e) { log.log(Level.SEVERE, "Could not access @PreDestroy method of managed bean " + name, e); } catch (InvocationTargetException e) { log.log(Level.SEVERE, "An Exception occured while invoking " + "@PreDestroy method of managed bean " + name, e); } } }
/** * Destroys the given managed bean. * @param name * @param instance */ public void destroy(String name, Object instance) { if (instance != null && isManagedBean(name)) { try { _lifecycleProvider.destroyInstance(instance); } catch (IllegalAccessException e) { log.log(Level.SEVERE, "Could not access @PreDestroy method of managed bean " + name, e); } catch (InvocationTargetException e) { log.log(Level.SEVERE, "An Exception occured while invoking " + "@PreDestroy method of managed bean " + name, e); } } }
/** * Destroys the given managed bean. * @param name * @param instance */ public void destroy(String name, Object instance) { if (instance != null && isManagedBean(name)) { try { _lifecycleProvider.destroyInstance(instance); } catch (IllegalAccessException e) { log.log(Level.SEVERE, "Could not access @PreDestroy method of managed bean " + name, e); } catch (InvocationTargetException e) { log.log(Level.SEVERE, "An Exception occured while invoking " + "@PreDestroy method of managed bean " + name, e); } } }