jackrabbit-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ju...@apache.org
Subject svn commit: r1478719 - in /jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core: RepositoryContext.java RepositoryImpl.java
Date Fri, 03 May 2013 10:39:45 GMT
Author: jukka
Date: Fri May  3 10:39:45 2013
New Revision: 1478719

URL: http://svn.apache.org/r1478719
Log:
JCR-3587: RepositoryImpl should expose the collection of PersistenceManager instances in use

Make the RepositoryConfig and WorkspaceInfo instances available through RepositoryContext

Modified:
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/RepositoryContext.java
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/RepositoryImpl.java

Modified: jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/RepositoryContext.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/RepositoryContext.java?rev=1478719&r1=1478718&r2=1478719&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/RepositoryContext.java
(original)
+++ jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/RepositoryContext.java
Fri May  3 10:39:45 2013
@@ -20,8 +20,10 @@ import java.io.File;
 import java.io.IOException;
 import java.util.concurrent.ScheduledExecutorService;
 
+import javax.jcr.NoSuchWorkspaceException;
 import javax.jcr.RepositoryException;
 
+import org.apache.jackrabbit.core.RepositoryImpl.WorkspaceInfo;
 import org.apache.jackrabbit.core.cluster.ClusterNode;
 import org.apache.jackrabbit.core.config.RepositoryConfig;
 import org.apache.jackrabbit.core.data.DataStore;
@@ -168,6 +170,10 @@ public class RepositoryContext {
         return create(RepositoryConfig.install(dir));
     }
 
+    public RepositoryConfig getRepositoryConfig() {
+        return repository.getConfig();
+    }
+
     /**
      * Returns the repository instance to which this context is associated.
      *
@@ -366,6 +372,21 @@ public class RepositoryContext {
     }
 
     /**
+     * Returns the {@link WorkspaceInfo} for the named workspace.
+     *
+     * @param workspaceName The name of the workspace whose {@link WorkspaceInfo}
+     *                      is to be returned. This must not be <code>null</code>.
+     * @return The {@link WorkspaceInfo} for the named workspace. This will
+     *         never be <code>null</code>.
+     * @throws NoSuchWorkspaceException If the named workspace does not exist.
+     * @throws RepositoryException If this repository has been shut down.
+     */
+    public WorkspaceInfo getWorkspaceInfo(String workspaceName)
+            throws NoSuchWorkspaceException, RepositoryException {
+        return repository.getWorkspaceInfo(workspaceName);
+    }
+
+    /**
      * Returns the security manager of this repository.
      *
      * @return security manager

Modified: jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/RepositoryImpl.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/RepositoryImpl.java?rev=1478719&r1=1478718&r2=1478719&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/RepositoryImpl.java
(original)
+++ jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/RepositoryImpl.java
Fri May  3 10:39:45 2013
@@ -1616,7 +1616,7 @@ public class RepositoryImpl extends Abst
      * representing the same named workspace, i.e. the same physical
      * storage.
      */
-    protected class WorkspaceInfo implements UpdateEventListener {
+    public class WorkspaceInfo implements UpdateEventListener {
 
         /**
          * workspace configuration (passed in constructor)



Mime
View raw message