private String defaultCatalogName;
public OptionsImpl(StandardServiceRegistry serviceRegistry) {
this.serviceRegistry = serviceRegistry;
ConfigurationService configService = serviceRegistry.getService( ConfigurationService.class );
// cache access type
defaultCacheAccessType = configService.getSetting(
AvailableSettings.DEFAULT_CACHE_CONCURRENCY_STRATEGY,
new ConfigurationService.Converter<AccessType>() {
@Override
public AccessType convert(Object value) {
return AccessType.fromExternalName( value.toString() );
}
}
);
useNewIdentifierGenerators = configService.getSetting(
AvailableSettings.USE_NEW_ID_GENERATOR_MAPPINGS,
new ConfigurationService.Converter<Boolean>() {
@Override
public Boolean convert(Object value) {
return Boolean.parseBoolean( value.toString() );
}
},
false
);
defaultSchemaName = configService.getSetting(
AvailableSettings.DEFAULT_SCHEMA,
new ConfigurationService.Converter<String>() {
@Override
public String convert(Object value) {
return value.toString();
}
},
null
);
defaultCatalogName = configService.getSetting(
AvailableSettings.DEFAULT_CATALOG,
new ConfigurationService.Converter<String>() {
@Override
public String convert(Object value) {
return value.toString();
}
},
null
);
globallyQuotedIdentifiers = configService.getSetting(
AvailableSettings.GLOBALLY_QUOTED_IDENTIFIERS,
new ConfigurationService.Converter<Boolean>() {
@Override
public Boolean convert(Object value) {
return Boolean.parseBoolean( value.toString() );