}
public Repository getRepository(RepositoryImplConfig config)
throws RepositoryConfigException
{
VirtuosoRepository result = null;
if (config instanceof VirtuosoRepositoryConfig) {
VirtuosoRepositoryConfig vConfig = (VirtuosoRepositoryConfig)config;
result = new VirtuosoRepository(vConfig.getHostList(),
vConfig.getUsername(),
vConfig.getPassword(),
vConfig.getDefGraph(),
vConfig.getUseLazyAdd());
result.setFetchSize(vConfig.getFetchSize());
result.setRoundrobin(vConfig.getRoundRobin());
result.setFetchSize(vConfig.getFetchSize());
result.setRuleSet(vConfig.getRuleSet());
result.setBatchSize(vConfig.getBatchSize());
}
else {
throw new RepositoryConfigException("Invalid configuration class: " + config.getClass());
}
return result;