jackrabbit-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ang...@apache.org
Subject svn commit: r450890 - in /jackrabbit/trunk/contrib/spi/jcr2spi/src/main/java/org/apache/jackrabbit/jcr2spi: RepositoryImpl.java config/RepositoryConfig.java
Date Thu, 28 Sep 2006 15:17:31 GMT
Author: angela
Date: Thu Sep 28 08:17:30 2006
New Revision: 450890

URL: http://svn.apache.org/viewvc?view=rev&rev=450890
Log:
work in progress

- retrieve default workspace name from config

Modified:
    jackrabbit/trunk/contrib/spi/jcr2spi/src/main/java/org/apache/jackrabbit/jcr2spi/RepositoryImpl.java
    jackrabbit/trunk/contrib/spi/jcr2spi/src/main/java/org/apache/jackrabbit/jcr2spi/config/RepositoryConfig.java

Modified: jackrabbit/trunk/contrib/spi/jcr2spi/src/main/java/org/apache/jackrabbit/jcr2spi/RepositoryImpl.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/contrib/spi/jcr2spi/src/main/java/org/apache/jackrabbit/jcr2spi/RepositoryImpl.java?view=diff&rev=450890&r1=450889&r2=450890
==============================================================================
--- jackrabbit/trunk/contrib/spi/jcr2spi/src/main/java/org/apache/jackrabbit/jcr2spi/RepositoryImpl.java
(original)
+++ jackrabbit/trunk/contrib/spi/jcr2spi/src/main/java/org/apache/jackrabbit/jcr2spi/RepositoryImpl.java
Thu Sep 28 08:17:30 2006
@@ -70,7 +70,8 @@
      * @see Repository#login(javax.jcr.Credentials, String)
      */
     public Session login(Credentials credentials, String workspaceName) throws LoginException,
NoSuchWorkspaceException, RepositoryException {
-        SessionInfo info = config.getRepositoryService().login(credentials, workspaceName);
+        String wspName = (workspaceName == null) ? config.getDefaultWorkspaceName() : workspaceName;
+        SessionInfo info = config.getRepositoryService().login(credentials, wspName);
         if (info instanceof XASessionInfo) {
             return new XASessionImpl((XASessionInfo) info, this, config);
         } else {

Modified: jackrabbit/trunk/contrib/spi/jcr2spi/src/main/java/org/apache/jackrabbit/jcr2spi/config/RepositoryConfig.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/contrib/spi/jcr2spi/src/main/java/org/apache/jackrabbit/jcr2spi/config/RepositoryConfig.java?view=diff&rev=450890&r1=450889&r2=450890
==============================================================================
--- jackrabbit/trunk/contrib/spi/jcr2spi/src/main/java/org/apache/jackrabbit/jcr2spi/config/RepositoryConfig.java
(original)
+++ jackrabbit/trunk/contrib/spi/jcr2spi/src/main/java/org/apache/jackrabbit/jcr2spi/config/RepositoryConfig.java
Thu Sep 28 08:17:30 2006
@@ -30,4 +30,6 @@
     public RepositoryService getRepositoryService() throws RepositoryException;
 
     public ValueFactory getValueFactory() throws RepositoryException;
+
+    public String getDefaultWorkspaceName();
 }



Mime
View raw message