/** * @see org.apache.wicket.resource.IPropertiesFactory#clearCache() */ @Override public final void clearCache() { if (propertiesCache != null) { propertiesCache.clear(); } // clear the localizer cache as well context.getLocalizer().clearCache(); }
/** * @see org.apache.wicket.resource.IPropertiesFactory#clearCache() */ @Override public final void clearCache() { if (propertiesCache != null) { propertiesCache.clear(); } // clear the localizer cache as well context.getLocalizer().clearCache(); }
/** * @see org.apache.wicket.resource.IPropertiesFactory#clearCache() */ public final void clearCache() { propertiesCache.clear(); // clear the localizer cache as well application.getResourceSettings().getLocalizer().clearCache(); }
/** * @see org.apache.wicket.jmx.ApplicationMBean#clearLocalizerCache() */ @Override public void clearLocalizerCache() throws IOException { application.getResourceSettings().getLocalizer().clearCache(); } }
public void onChange() { log.info("A properties files has changed. Removing all entries " + "from the cache. Resource: " + resourceStream); // Clear the whole cache as associated localized files may // be affected and may need reloading as well. clearCache(); // clear the localizer cache as well application.getResourceSettings().getLocalizer().clearCache(); // Inform all listeners Iterator iter = afterReloadListeners.iterator(); while (iter.hasNext()) { IPropertiesChangeListener listener = (IPropertiesChangeListener)iter.next(); try { listener.propertiesChanged(key); } catch (Throwable ex) { log.error("PropertiesReloadListener has thrown an exception: " + ex.getMessage()); } } } });
private void invalidateCache() { OrienteerWebApplication app = OrienteerWebApplication.lookupApplication(); if(app!=null) { app.getResourceSettings().getLocalizer().clearCache(); } }
/** Clears all the wicket caches so that resources and localization files will be re-read */ public void clearWicketCaches() { getResourceSettings().getPropertiesFactory().clearCache(); getResourceSettings().getLocalizer().clearCache(); }
/** * Clears all the wicket caches so that resources and localization files will be re-read */ public void clearWicketCaches() { getResourceSettings().getPropertiesFactory().clearCache(); getResourceSettings().getLocalizer().clearCache(); }
/** * Clears the i18n cache so that localized keys can be reloaded. * * <p> * Have hidden this service because it seems that Wicket automatically invalidates * the resource cache anyway if running in development/prototype mode. * </p> */ @Action( restrictTo = RestrictTo.PROTOTYPING, hidden = Where.EVERYWHERE, semantics = SemanticsOf.IDEMPOTENT ) public void resetI18nCache() { Application.get() .getResourceSettings() .getLocalizer().clearCache(); } }
/** * Clears the i18n cache so that localized keys can be reloaded. * * <p> * Have hidden this service because it seems that Wicket automatically invalidates * the resource cache anyway if running in development/prototype mode. * </p> */ @Action( restrictTo = RestrictTo.PROTOTYPING, hidden = Where.EVERYWHERE, semantics = SemanticsOf.IDEMPOTENT ) public void resetI18nCache() { Application.get() .getResourceSettings() .getLocalizer().clearCache(); } }