public void setConfiguration(Configuration conf) { _conf = (OpenJPAConfiguration) conf; _log = conf.getConfigurationLog(); }
public void setConfiguration(Configuration conf) { this.conf = (OpenJPAConfiguration) conf; this.log = conf.getLog(OpenJPAConfiguration.LOG_DATACACHE); }
/** * A string to prefix all log messages with. Set to * <code>null</code> to use the configuration's Id property setting. */ public String getDiagnosticContext() { if (!_diagContextComputed) { // this initialization has to happen lazily because there is no // guarantee that conf.getId() will be populated by the time that // endConfiguration() is called. if (_diagContext == null && _conf != null) { _diagContext = _conf.getId(); } if ("".equals(_diagContext)) _diagContext = null; _diagContextComputed = true; } return _diagContext; }
cls = loadClass(clsName, findDerivedLoader(conf, null)); if (cls == null && conf.getUserClassLoader() != null) { cls = loadClass(clsName, conf.getUserClassLoader()); if (fatal) throw getCreateException(clsName, val, new ClassNotFoundException(clsName)); Log log = (conf == null) ? null : conf.getConfigurationLog(); if (log != null && log.isErrorEnabled()) log.error(_loc.get("plugin-creation-exception", val)); if (fatal) throw re; Log log = (conf == null) ? null : conf.getConfigurationLog(); if (log != null && log.isErrorEnabled()) log.error(_loc.get("plugin-creation-exception", val), re);
boolean containsReadOnlyConfigurationAsListener() { if (listeners == null) return false; for (ValueListener listener : listeners) { if (listener instanceof Configuration && ((Configuration)listener).isReadOnly()) return true; } return false; }
/** * Set properties into configuration. If the log is non-null, will log * a TRACE message about the set. */ protected void setInto(Configuration conf, Log log) { if (log != null && log.isTraceEnabled()) log.trace(_loc.get("conf-load", getProperties())); if (_props != null) conf.fromProperties(_props); } }
cls = loadClass(clsName, findDerivedLoader(conf, null)); if (cls == null && conf.getUserClassLoader() != null) { cls = loadClass(clsName, conf.getUserClassLoader()); if (fatal) throw getCreateException(clsName, val, new ClassNotFoundException(clsName)); Log log = (conf == null) ? null : conf.getConfigurationLog(); if (log != null && log.isErrorEnabled()) log.error(_loc.get("plugin-creation-exception", val)); if (fatal) throw re; Log log = (conf == null) ? null : conf.getConfigurationLog(); if (log != null && log.isErrorEnabled()) log.error(_loc.get("plugin-creation-exception", val), re);
boolean containsReadOnlyConfigurationAsListener() { if (listeners == null) return false; for (ValueListener listener : listeners) { if (listener instanceof Configuration && ((Configuration)listener).isReadOnly()) return true; } return false; }
/** * Set properties into configuration. If the log is non-null, will log * a TRACE message about the set. */ protected void setInto(Configuration conf, Log log) { if (log != null && log.isTraceEnabled()) log.trace(_loc.get("conf-load", getProperties())); if (_props != null) conf.fromProperties(_props); } }
private Log getLog() { return _conf.getConfigurationLog(); }
public void setConfiguration(Configuration conf) { this.conf = (OpenJPAConfiguration) conf; this.log = conf.getLog(OpenJPAConfiguration.LOG_DATACACHE); }
cls = loadClass(clsName, findDerivedLoader(conf, null)); if (cls == null && conf.getUserClassLoader() != null) { cls = loadClass(clsName, conf.getUserClassLoader()); if (fatal) throw getCreateException(clsName, val, new ClassNotFoundException(clsName)); Log log = (conf == null) ? null : conf.getConfigurationLog(); if (log != null && log.isErrorEnabled()) log.error(_loc.get("plugin-creation-exception", val)); if (fatal) throw re; Log log = (conf == null) ? null : conf.getConfigurationLog(); if (log != null && log.isErrorEnabled()) log.error(_loc.get("plugin-creation-exception", val), re);
boolean containsReadOnlyConfigurationAsListener() { if (listeners == null) return false; for (ValueListener listener : listeners) { if (listener instanceof Configuration && ((Configuration)listener).isReadOnly()) return true; } return false; }
/** * Set properties into configuration. If the log is non-null, will log * a TRACE message about the set. */ protected void setInto(Configuration conf, Log log) { if (log != null && log.isTraceEnabled()) log.trace(_loc.get("conf-load", getProperties())); if (_props != null) conf.fromProperties(_props); } }
/** * A string to prefix all log messages with. Set to * <code>null</code> to use the configuration's Id property setting. */ public String getDiagnosticContext() { if (!_diagContextComputed) { // this initialization has to happen lazily because there is no // guarantee that conf.getId() will be populated by the time that // endConfiguration() is called. if (_diagContext == null && _conf != null) { _diagContext = _conf.getId(); } if ("".equals(_diagContext)) _diagContext = null; _diagContextComputed = true; } return _diagContext; }
private Log getLog() { return _conf.getConfigurationLog(); }
public void setConfiguration(Configuration conf) { _log = conf.getLog(OpenJPAConfiguration.LOG_RUNTIME); }
/** * Asserts if this receiver can be changed. * Subclasses <em>must</em> invoke this method before changing its * internal state. * * This receiver can not be changed if all of the following is true * <LI>this receiver is not dynamic * <LI>ValueListener attached to this receiver is a Configuration * <LI>Configuration is read-only */ protected void assertChangeable() { if (!isDynamic() && listen instanceof Configuration && ((Configuration)listen).isReadOnly()) { throw new RuntimeException(s_loc.get("veto-change", this.getProperty()).toString()); } }
/** * Set properties into configuration. If the log is non-null, will log * a TRACE message about the set. */ protected void setInto(Configuration conf, Log log) { if (log != null && log.isTraceEnabled()) log.trace(_loc.get("conf-load", getProperties())); if (_props != null) conf.fromProperties(_props); } }
/** * A string to prefix all log messages with. Set to * <code>null</code> to use the configuration's Id property setting. */ public String getDiagnosticContext() { if (!_diagContextComputed) { // this initialization has to happen lazily because there is no // guarantee that conf.getId() will be populated by the time that // endConfiguration() is called. if (_diagContext == null && _conf != null) { _diagContext = _conf.getId(); } if ("".equals(_diagContext)) _diagContext = null; _diagContextComputed = true; } return _diagContext; }