1
2
3
4
5
6 package org.openrdf.repository.threadproxy;
7
8 import org.openrdf.repository.Repository;
9 import org.openrdf.repository.RepositoryConnection;
10 import org.openrdf.repository.RepositoryException;
11 import org.openrdf.repository.base.RepositoryWrapper;
12
13
14
15
16
17
18
19 public class ThreadProxyRepository extends RepositoryWrapper {
20
21 private ThreadProxyRepositoryConnection con;
22
23 public ThreadProxyRepository() {
24 super();
25 }
26
27 public ThreadProxyRepository(Repository repository) {
28 super(repository);
29 }
30
31 @Override
32 public void setDelegate(Repository repository) {
33 super.setDelegate(repository);
34 con = new ThreadProxyRepositoryConnection(this);
35 }
36
37 @Override
38 public RepositoryConnection getConnection() throws RepositoryException {
39 con.getDelegate();
40 return con;
41 }
42 }