/*
(non-Javadoc)

@see net.jawr.web.resource.bundle.factory.util.ConfigPropertiesSource#
configChanged()
181069
@Override
	public final boolean configChanged() {
		int currentConfigHash = doReadConfig().hashCode();
		boolean configChanged = this.propsHashCode != currentConfigHash;

		if (configChanged && LOGGER.isDebugEnabled()){
			LOGGER.debug("Changes in Jawr configuration properties file detected.");
		}
		
		this.propsHashCode = currentConfigHash;

		return configChanged;
	}
81074
public void setConfig(Map<String, ? extends CacheConfig> config) {
        this.configMap = (Map<String, CacheConfig>) config;
    }
664753
public void configSourceLoaded(Object source) {
        Properties props = ConfigurationConverter.getProperties(ConfigurationManager.getConfigInstance());
        reconfigure(props);
    }
1001546
protected void modified(ComponentContext context, Map<String, Object> properties) {
        if (TraceComponent.isAnyTracingEnabled() && LoggingUtil.SESSION_LOGGER_WAS.isLoggable(Level.FINE)) {
            LoggingUtil.SESSION_LOGGER_WAS.logp(Level.FINE, methodClassName, "modified", "context=" + context);
            LoggingUtil.SESSION_LOGGER_WAS.logp(Level.FINE, methodClassName, "modified", "properties=" + properties);
        }
        configurationProperties = properties;
    }
843738
public void checkRequired(String key) throws InitializationFailedException {
    if (properties.get(key) == null && getConfigurationValue(key) == null) {
      throw new InitializationFailedException("Missing required property in config: " + key);
    }
  }
836515
private void initializeConfig() {
    this.varDecay = this.config.varDecay;
    this.varInc = this.config.varInc;
    this.ccminMode = this.config.clauseMin;
    this.restartFirst = this.config.restartFirst;
    this.restartInc = this.config.restartInc;
    this.clauseDecay = this.config.clauseDecay;
    this.removeSatisfied = this.config.removeSatisfied;
    this.learntsizeFactor = this.config.learntsizeFactor;
    this.learntsizeInc = this.config.learntsizeInc;
    this.incremental = this.config.incremental;
  }
562327
@Override
	public final Properties getConfigProperties() {
		Properties props = doReadConfig();

		// Initialize hashcode of newly loaded properties.
		if (0 == this.propsHashCode) {
			this.propsHashCode = props.hashCode();
		}

		return props;
	}
825542
protected void selectSREFromConfig(ILaunchConfiguration config) {
		final boolean notify = this.sreBlock.getNotify();
		final boolean changed;
		try {
			this.sreBlock.setNotify(false);
			if (this.accessor.getUseSystemSREFlag(config)) {
				changed = this.sreBlock.selectSystemWideSRE();
			} else if (this.accessor.getUseProjectSREFlag(config)) {
				changed = this.sreBlock.selectProjectSRE();
			} else {
				final String sreId = this.accessor.getSREId(config);
				final ISREInstall sre = SARLRuntime.getSREFromId(Strings.nullToEmpty(sreId));
				changed = this.sreBlock.selectSpecificSRE(sre);
			}
		} finally {
			this.sreBlock.setNotify(notify);
		}
		if (changed) {
			updateLaunchConfigurationDialog();
		}
	}
1195677
private boolean configUpdated() {
        try {
            URL url = ctx.getResource(resourcesDir + configResource);
            URLConnection con;
            if (url == null) return false ;
            con = url.openConnection();
            long lastModified = con.getLastModified();
            long XHP_LAST_MODIFIEDModified = 0;
            if (ctx.getAttribute(XHP_LAST_MODIFIED) != null) {
                XHP_LAST_MODIFIEDModified = ((Long)ctx.getAttribute(XHP_LAST_MODIFIED)).longValue();
            } else {
                ctx.setAttribute(XHP_LAST_MODIFIED, new Long(lastModified));
                return false;
            }
            if (XHP_LAST_MODIFIEDModified < lastModified) {
                ctx.setAttribute(XHP_LAST_MODIFIED, new Long(lastModified));
                return true;
            }
        } catch (Exception ex) {
            getLogger().severe("XmlHttpProxyServlet error checking configuration: " + ex);
        }
        return false;
    }
1266349
function onConfigLoad() {
  var file = this._conf.get(ConfigName.LOGFILE);
  this._logger.level(this._conf.get(ConfigName.LOGLEVEL));
  //console.dir('config loaded.');
  if(file && !this._conf.get(ConfigName.DAEMONIZE)) {
    this._logger.stream(file);
  }
  if(this._conf.isDefault()) {
    this._logger.warning('no config file specified, using the default config');
  }

  // TODO: listen for log change events and toggle this
  this._scheduler.startDebugLog();

  this._scheduler.start(this._conf.get(ConfigName.HZ));
}
516915
@Override
    public String getChangedProperties(WebAppSecurityConfig original) {
        WebAppSecurityConfig globalConfig = WebAppSecurityCollaboratorImpl.getGlobalWebAppSecurityConfig();
        if (globalConfig != null) {
            return globalConfig.getChangedProperties(original);
        } else {
            return "";
        }
    }
469670
@Override
    public void configurationChanged() {

        HashSet<Param> changedParams = new HashSet();

        // read dynamic parameters
        for (Param param : parameters) {

            if (! param.isStatic()) {

                // preserve current value
                Object oldValue = param.getValue();

                // read new value
                readAndValidateParameter(param);

                // get if parameter value had changed
                if (! ConfigUtil.equalValues(oldValue, param.getValue())) {
                    changedParams.add(param);
                }
            }

        }

        // invoke listeners for all changed parameters
        if (! changedParams.isEmpty()) {

            for (ConfigChangeListener listener : configChangeListeners) {
                listener.configurationChanged(changedParams);
            }

        }

    }
1287486
public void clearUnused(ConfigImpl config) {

	SystemOut.printDate(config.getOutWriter(), "PagePool: " + size() + ">(" + maxSize + ")");
	if (size() > maxSize) {
	    String[] keys = keys();
	    LongKeyList list = new LongKeyList();
	    for (int i = 0; i < keys.length; i++) {
		PageSource ps = getPageSource(keys[i], false);
		long updateTime = ps.getLastAccessTime();
		if (updateTime + timeout < System.currentTimeMillis()) {
		    long add = ((ps.getAccessCount() - 1) * 10000);
		    if (add > timeout) add = timeout;
		    list.add(updateTime + add, keys[i]);
		}
	    }
	    while (size() > maxSize) {
		Object key = list.shift();
		if (key == null) break;
		remove(key.toString());
	    }
	}
    }
1239642
@Override
	public synchronized void configLoaded(IConfig config, long sequence) {
		String previousRawConfig = rawConfig;
		rawConfig = config.toString();

		if (previousRawConfig == null || !previousRawConfig.equals(rawConfig)) {
			processDeps(validate, false, sequence);
			validate = false;
		}
	}
975509
public synchronized static void initConfig() {
        SeLionLogger.getLogger().entering();
        Map<ConfigProperty, String> initialValues = new HashMap<>();

        initConfig(initialValues);

        SeLionLogger.getLogger().exiting();
    }
169380
public final void init(final ConfigurationState configState) {
    final ConstraintValidatorFactory configConstraintValidatorFactory =
        configState.getConstraintValidatorFactory();
    constraintValidatorFactory = configConstraintValidatorFactory == null
        ? GWT.<ConstraintValidatorFactory>create(ConstraintValidatorFactory.class)
        : configConstraintValidatorFactory;
    final TraversableResolver configTraversableResolver = configState.getTraversableResolver();
    traversableResolver = configTraversableResolver == null ? new DefaultTraversableResolver()
        : configTraversableResolver;
    final MessageInterpolator configMessageInterpolator = configState.getMessageInterpolator();
    messageInterpolator = configMessageInterpolator == null ? new GwtMessageInterpolator()
        : configMessageInterpolator;
    parameterNameProvider = configState.getParameterNameProvider();
  }
1300655
protected void updateLaunchOptionsFromConfig(ILaunchConfiguration config) {
		final boolean showLogo = this.accessor.getShowLogoFlag(config);
		final boolean showLogInfo = this.accessor.getShowLogInfoFlag(config);
		final boolean offline = this.accessor.getOfflineFlag(config);
		final boolean runInEclipse = this.accessor.isEmbeddedSRE(config);
		final boolean enableAssertionsRun = this.accessor.isAssertionEnabledInRunMode(config);
		final boolean enableAssertionsDebug = this.accessor.isAssertionEnabledInDebugMode(config);
		this.showLogoOptionButton.setSelection(showLogo);
		this.showLogInfoButton.setSelection(showLogInfo);
		this.offlineButton.setSelection(offline);
		this.enableAssertionsInRunModeButton.setSelection(enableAssertionsRun);
		this.enableAssertionsInDebugModeButton.setSelection(enableAssertionsDebug);
		this.runInEclipseButton.setSelection(runInEclipse);
	}