View Javadoc

1   /*
2    * Copyright Aduna (http://www.aduna-software.com/) (c) 2007.
3    *
4    * Licensed under the Aduna BSD-style license.
5    */
6   package org.openrdf.repository.flushable;
7   
8   import org.openrdf.repository.Repository;
9   import org.openrdf.repository.config.DelegatingRepositoryImplConfigBase;
10  import org.openrdf.repository.config.RepositoryConfigException;
11  import org.openrdf.repository.config.RepositoryFactory;
12  import org.openrdf.repository.config.RepositoryImplConfig;
13  
14  /**
15   * @author Arjohn Kampman
16   */
17  public class FlushableRepositoryFactory implements RepositoryFactory {
18  
19  	public static final String REPOSITORY_TYPE = "openrdf:FlushableRepository";
20  
21  	public String getRepositoryType() {
22  		return REPOSITORY_TYPE;
23  	}
24  
25  	public RepositoryImplConfig getConfig() {
26  		return new DelegatingRepositoryImplConfigBase(REPOSITORY_TYPE);
27  	}
28  
29  	public Repository getRepository(RepositoryImplConfig config)
30  			throws RepositoryConfigException {
31  		return new FlushableRepository();
32  	}
33  }