if (isUnicodeSemantics())
_impl.getQuercus().setUnicodeSemantics(true);
_impl.init(config);
QuercusContext quercus = getQuercus();
quercus.setCompile(_isCompile);
quercus.setLazyCompile(_isLazyCompile);
quercus.setCompileFailover(_isCompileFailover);
quercus.setProfileProbability(_profileProbability);
quercus.setRequireSource(_isRequireSource);
quercus.setDatabase(_database);
quercus.setStrict(_isStrict);
quercus.setLooseParse(_isLooseParse);
quercus.setPageCacheSize(_pageCacheSize);
quercus.setRegexpCacheSize(_regexpCacheSize);
quercus.setConnectionPool(_isConnectionPool);
if (_iniPath != null) {
String realPath = getServletContext().getRealPath(_iniPath);
quercus.setIniFile(getQuercus().getPwd().lookup(realPath));
}
if (_scriptEncoding != null)
quercus.setScriptEncoding(_scriptEncoding);
if (_mysqlVersion != null)
quercus.setMysqlVersion(_mysqlVersion);
if (_phpVersion != null)
quercus.setPhpVersion(_phpVersion);
for (QuercusModule module : _moduleList) {
quercus.addModule(module);
}
for (PhpClassConfig cls : _classList) {
quercus.addJavaClass(cls.getName(), cls.getType());
}
for (PhpClassConfig cls : _classImplList) {
quercus.addImplClass(cls.getName(), cls.getType());
}
for (PhpIni ini : _phpIniList) {
for (Map.Entry<String,String> entry : ini._propertyMap.entrySet()) {
quercus.setIni(entry.getKey(), entry.getValue());
}
}
for (ServerEnv serverEnv : _serverEnvList) {
for (Map.Entry<String,String> entry
: serverEnv._propertyMap.entrySet()) {
quercus.setServerEnv(entry.getKey(), entry.getValue());
}
}
}